Compare commits

...

73 Commits

Author SHA1 Message Date
Marcus Schiesser f6dabd0d3e RELEASING: Releasing 1 package(s)
Releases:
  create-llama@0.0.22

[skip ci]
2024-02-01 15:51:44 +07:00
Marcus Schiesser 74caaa2bf7 fix: clarify CLI output for create-llama 2024-02-01 15:26:48 +07:00
Marcus Schiesser 552403b370 fix: don't create d.ts files for create-llama 2024-02-01 14:33:29 +07:00
Huu Le (Lee) a93d09d159 fix(create-llama): generate code option fail (#491) 2024-02-01 10:57:10 +07:00
Thuc Pham 0fb757f6c1 feat: use pnpm pack for e2e (#490) 2024-02-01 10:12:21 +07:00
Alex Yang a68053ca4e fix: remove as any type (#494) 2024-02-01 10:10:41 +07:00
Alex Yang 36d4f4027b RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.7

[skip ci]
2024-01-31 17:20:26 -06:00
Alex Yang 19d92507e3 chore: use the patch version 2024-01-31 17:20:17 -06:00
Emanuel Ferreira 664e92a3d6 chore: remove collapsed router query (#497) 2024-01-31 16:31:49 -06:00
Emanuel Ferreira d687c110e4 docs(changeset): feat(router): add router query engine (#496) 2024-01-31 14:24:51 -08:00
Emanuel Ferreira af5ae7054e feat(router): setup router query engine (#484) 2024-01-31 13:58:47 -08:00
Alex Yang dff1e7f552 RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.6

[skip ci]
2024-01-31 12:50:40 -06:00
Alex Yang cf446401e5 fix: instanceof issue (#492) 2024-01-31 12:45:02 -06:00
Huu Le (Lee) e9b87ef09b feat(create-llama) add folder selection & support more context data types (#489) 2024-01-31 16:42:30 +07:00
yisding 7231ddb1b3 allow simpledirectoryreader to get a string (#488)
Co-authored-by: Alex Yang <himself65@outlook.com>
2024-01-31 11:11:57 +07:00
Alex Yang 1ead36f1bb RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.5

[skip ci]
2024-01-30 14:21:37 -06:00
Alex Yang 8a9b78a4ab docs(changeset): chore: split readers into different files 2024-01-30 14:21:17 -06:00
Motoki saito 569299724a add --vector-db option to create-llama (#473) 2024-01-30 15:24:35 +07:00
Huu Le (Lee) 6dd401e1c7 Feat: add + fix chat with web (#481) 2024-01-30 14:17:33 +07:00
Marcus Schiesser c4cb37786b fix: use Array not Float32Array (#482) 2024-01-30 11:28:14 +07:00
Alex Yang b757d9a94e chore: split readers into different files (#479) 2024-01-29 22:05:23 -06:00
Motoki saito 6cc083f370 define mergePoetryDependencies type (#465) 2024-01-30 10:47:41 +07:00
yisding c419027db9 add docs for azure openai (#480) 2024-01-30 10:41:05 +07:00
metonym 6a16b47406 Fix typo in node_parser.md (#475) 2024-01-30 10:34:53 +07:00
Alex Yang 4197ae8b9f RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.4

[skip ci]
2024-01-29 18:30:54 -06:00
Alex Yang 88696e1407 refactor: use pdf2json instead of pdfjs-dist (#477) 2024-01-29 18:28:20 -06:00
Marcus Schiesser 24cb48f195 RELEASING: Releasing 1 package(s)
Releases:
      create-llama@0.0.21

    [skip ci]
2024-01-29 17:38:57 +07:00
Marcus Schiesser 965cfd291e fix: use pipeline instead of nodeparser (#471) 2024-01-29 17:31:09 +07:00
Marcus Schiesser 873329c052 Revert "feat: Add chat with web data (#450)"
This reverts commit 27d55fde8c.
2024-01-29 17:28:16 +07:00
Marcus Schiesser 3d8023b9a9 feat: add ingestion pipeline cache (#442) 2024-01-29 16:45:09 +07:00
Marcus Schiesser 93d1450fc1 RELEASING: Releasing 1 package(s)
Releases:
  create-llama@0.0.20

[skip ci]
2024-01-29 16:37:42 +07:00
Huu Le (Lee) 27d55fde8c feat: Add chat with web data (#450) 2024-01-29 14:16:57 +07:00
Marcus Schiesser 690399b04c feat: also test context template engine (#470) 2024-01-29 11:36:35 +07:00
hiepxanh 65b84f1ab3 docs: fix dead link (#452) 2024-01-28 12:11:40 -06:00
Ian Sinnott 835acb89d0 docs: remove unused arg in qdrant docs (#461) 2024-01-28 12:11:29 -06:00
Alex Yang d9df9ea75c RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.3

[skip ci]
2024-01-28 11:59:22 -06:00
Alex Yang 06874ffb69 fix: cannot run examples 2024-01-28 11:59:02 -06:00
Alex Yang f0898a3930 fix: ignore release examples 2024-01-28 11:57:16 -06:00
Alex Yang 7d50196d2f fix: output edge-light (#469) 2024-01-28 11:51:12 -06:00
Emanuel Ferreira f90f7fee64 docs: ingestion pipeline, transformations (#464) 2024-01-27 11:53:52 -03:00
Emanuel Ferreira 3d860df873 chore: update example (#463) 2024-01-27 10:11:50 -03:00
Emanuel Ferreira 2fe3a2b6a8 chore: enhancement optional args extractors (#462) 2024-01-27 09:18:17 -03:00
Emanuel Ferreira eb3d4af204 docs: usage metadata extraction (#460) 2024-01-27 08:37:24 -03:00
Alex Yang 0652352e92 chore: fix circular dependency (#459) 2024-01-27 00:46:04 -06:00
Alex Yang 103949513b chore: bump version (#458) 2024-01-26 22:46:00 -06:00
Emanuel Ferreira 9ba4547c4d fix: not overwrite metadata (#453) 2024-01-26 09:07:52 -03:00
Tyrone Avnit 4fea0adf43 Expose BaseExtractor Class (#454) 2024-01-26 09:07:36 -03:00
Marcus Schiesser de070dbfa7 RELEASING: Releasing 1 package(s)
Releases:
  create-llama@0.0.19

[skip ci]
2024-01-26 16:33:12 +07:00
Marcus Schiesser 87eb72bdb2 fix: don't install root package for llamapack examples (as there isn't one) 2024-01-26 16:30:50 +07:00
Thuc Pham fe03aaae55 feat: generate llama pack example (#429) 2024-01-26 15:02:49 +07:00
yisding 9ce7d3d648 Update packages (#448) 2024-01-26 11:54:58 +07:00
Alex Yang 0471407761 RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.2

[skip ci]
2024-01-25 22:26:59 -06:00
Alex Yang e4b807a018 fix(core): invalid package.json 2024-01-25 22:26:31 -06:00
Alex Yang 0a0ec37725 RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.1.1

[skip ci]
2024-01-25 22:18:14 -06:00
Alex Yang 8abca5d818 build(core): release with node resolution compatibility (#451) 2024-01-25 22:12:15 -06:00
jess-render 3a29a8036b Add node_modules to gitignore in Express backends (#447)
Co-authored-by: Jess Lin <jesslin@Jesss-MBP.render.com>
2024-01-26 09:34:53 +07:00
yisding e2b9b66f71 RELEASING: Releasing 2 package(s)
Releases:
  llamaindex@0.1.0
  docs@0.0.1

[skip ci]
2024-01-25 15:47:02 -08:00
yisding bb66cb7e36 Openai embeddings 3 (#445) 2024-01-25 15:45:21 -08:00
Alex Yang 2159e77c9d RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.0.51

[skip ci]
2024-01-25 14:59:22 -06:00
Emanuel Ferreira 3154f521d9 chore: add qdrant readme (#444) 2024-01-25 17:58:37 -03:00
Alex Yang fda8024607 revert: export conditions not working with moduleResolution node (#443) 2024-01-25 13:51:05 -06:00
Marcus Schiesser 89336e4ddf feat: add deno jupyter examples (#428) 2024-01-25 18:09:19 +07:00
Marcus Schiesser a94f747307 RELEASING: Releasing 1 package(s)
Releases:
  create-llama@0.0.18

[skip ci]
2024-01-25 17:46:19 +07:00
Marcus Schiesser 88d3b41044 fix: create-llama packaging 2024-01-25 17:44:29 +07:00
Marcus Schiesser 7fd02ab8d1 RELEASING: Releasing 1 package(s)
Releases:
  create-llama@0.0.17

[skip ci]
2024-01-25 16:58:45 +07:00
Huu Le (Lee) 9e5d8e143e Feat: add local pdf file option (#441) 2024-01-25 15:20:42 +07:00
Huu Le (Lee) f0f7df29b3 remove chromadb override (as llamaindex is forcing now chromadb 1.7.3) 2024-01-25 14:24:01 +07:00
yisding 05ba70881c RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.0.50

[skip ci]
2024-01-24 23:00:50 -08:00
yisding 8a729cdd0d minor bug fixes with together AI (#440) 2024-01-24 22:59:09 -08:00
Marcus Schiesser ffe5fbcd51 RELEASING: Releasing 1 package(s)
Releases:
  llamaindex@0.0.49

[skip ci]
2024-01-25 11:09:36 +07:00
Marcus Schiesser 18cc545e16 chore: allow separate releases for create-llama and llamaindex 2024-01-25 11:09:22 +07:00
Emanuel Ferreira c818e90cfc refactor: restructure documentation (#420)
Co-authored-by: Alex Yang <himself65@outlook.com>
2024-01-25 10:22:35 +07:00
Alex Yang 570973b9d6 docs: add stackblitz playground (#439) 2024-01-24 21:00:47 -06:00
219 changed files with 5393 additions and 3253 deletions
-5
View File
@@ -1,5 +0,0 @@
---
"llamaindex": patch
---
feat(qdrant): Add Qdrant Vector DB
-5
View File
@@ -1,5 +0,0 @@
---
"llamaindex": patch
---
Preview: Add ingestion pipeline (incl. different strategies to handle doc store duplicates)
-5
View File
@@ -1,5 +0,0 @@
---
"create-llama": patch
---
Add an option that allows the user to run the generated app
-16
View File
@@ -1,16 +0,0 @@
---
"llamaindex": patch
---
feat: use conditional exports
The benefit of conditional exports is we split the llamaindex into different files. This will improve the tree shake if you are building web apps.
This also requires node16 (see https://nodejs.org/api/packages.html#conditional-exports).
If you are seeing typescript issue `TS2724`('llamaindex' has no exported member named XXX):
1. update `moduleResolution` to `bundler` in `tsconfig.json`, more for the web applications like Next.js, and vite, but still works for ts-node or tsx.
2. consider the ES module in your project, add `"type": "module"` into `package.json` and update `moduleResolution` to `node16` or `nodenext` in `tsconfig.json`.
We still support both cjs and esm, but you should update `tsconfig.json` to make the typescript happy.
-5
View File
@@ -1,5 +0,0 @@
---
"llamaindex": patch
---
feat(extractors): add keyword extractor and base extractor
+6
View File
@@ -49,6 +49,12 @@ jobs:
- name: Build create-llama
run: pnpm run build
working-directory: ./packages/create-llama
- name: Pack
run: pnpm pack --pack-destination ./output
working-directory: ./packages/create-llama
- name: Extract Pack
run: tar -xvzf ./output/*.tgz -C ./output
working-directory: ./packages/create-llama
- name: Run Playwright tests
run: pnpm exec playwright test
env:
+30 -2
View File
@@ -32,7 +32,35 @@ jobs:
- name: Install dependencies
run: pnpm install
- name: Build
run: pnpm run build
working-directory: ./packages/core
run: pnpm run build --filter llamaindex
- name: Run Type Check
run: pnpm run type-check
- name: Run Circular Dependency Check
run: pnpm run circular-check
working-directory: ./packages/core
typecheck-examples:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Build
run: pnpm run build --filter llamaindex
- name: Copy examples
run: rsync -rv --exclude=node_modules ./examples ${{ runner.temp }}
- name: Pack
run: pnpm pack --pack-destination ${{ runner.temp }}
working-directory: packages/core
- name: Install llamaindex
run: npm add ${{ runner.temp }}/*.tgz
working-directory: ${{ runner.temp }}/examples
- name: Run Type Check
run: npx tsc --project ./tsconfig.json
working-directory: ${{ runner.temp }}/examples
-3
View File
@@ -1,6 +1,3 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
pnpm format
pnpm lint
npx lint-staged
-3
View File
@@ -1,4 +1 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
pnpm test
+1
View File
@@ -1 +1,2 @@
auto-install-peers = true
enable-pre-post-scripts = true
+1
View File
@@ -1,4 +1,5 @@
apps/docs/i18n
apps/docs/docs/api
pnpm-lock.yaml
lib/
dist/
+3
View File
@@ -8,5 +8,8 @@
"jest.rootPath": "./packages/core",
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
}
+7
View File
@@ -11,6 +11,10 @@ Use your own data with large language models (LLMs, OpenAI ChatGPT and others) i
Documentation: https://ts.llamaindex.ai/
Try examples online:
[![Open in Stackblitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/run-llama/LlamaIndexTS/tree/main/examples)
## What is LlamaIndex.TS?
LlamaIndex.TS aims to be a lightweight, easy to use set of libraries to help you integrate large language models into your applications with your own data.
@@ -101,6 +105,9 @@ export const runtime = "nodejs"; // default
// next.config.js
/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
serverComponentsExternalPackages: ["pdf2json"],
},
webpack: (config) => {
config.resolve.alias = {
...config.resolve.alias,
+7
View File
@@ -0,0 +1,7 @@
# docs
## 0.0.1
### Patch Changes
- 3154f52: chore: add qdrant readme
-49
View File
@@ -1,49 +0,0 @@
---
sidebar_position: 4
---
# End to End Examples
We include several end-to-end examples using LlamaIndex.TS in the repository
Check out the examples below or try them out and complete them in minutes with interactive Github Codespace tutorials provided by Dev-Docs [here](https://codespaces.new/team-dev-docs/lits-dev-docs-playground?devcontainer_path=.devcontainer%2Fjavascript_ltsquickstart%2Fdevcontainer.json):
## [Chat Engine](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/chatEngine.ts)
Read a file and chat about it with the LLM.
## [Vector Index](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/vectorIndex.ts)
Create a vector index and query it. The vector index will use embeddings to fetch the top k most relevant nodes. By default, the top k is 2.
## [Summary Index](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/summaryIndex.ts)
Create a list index and query it. This example also use the `LLMRetriever`, which will use the LLM to select the best nodes to use when generating answer.
## [Save / Load an Index](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/storageContext.ts)
Create and load a vector index. Persistance to disk in LlamaIndex.TS happens automatically once a storage context object is created.
## [Customized Vector Index](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/vectorIndexCustomize.ts)
Create a vector index and query it, while also configuring the `LLM`, the `ServiceContext`, and the `similarity_top_k`.
## [OpenAI LLM](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/openai.ts)
Create an OpenAI LLM and directly use it for chat.
## [Llama2 DeuceLLM](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/llamadeuce.ts)
Create a Llama-2 LLM and directly use it for chat.
## [SubQuestionQueryEngine](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/subquestion.ts)
Uses the `SubQuestionQueryEngine`, which breaks complex queries into multiple questions, and then aggreates a response across the answers to all sub-questions.
## [Low Level Modules](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/lowlevel.ts)
This example uses several low-level components, which removes the need for an actual query engine. These components can be used anywhere, in any application, or customized and sub-classed to meet your own needs.
## [JSON Entity Extraction](https://github.com/run-llama/LlamaIndexTS/blob/main/examples/jsonExtract.ts)
Features OpenAI's chat API (using [`json_mode`](https://platform.openai.com/docs/guides/text-generation/json-mode)) to extract a JSON object from a sales call transcript.
+2
View File
@@ -0,0 +1,2 @@
label: Examples
position: 2
+12
View File
@@ -0,0 +1,12 @@
---
sidebar_position: 1
---
import CodeBlock from "@theme/CodeBlock";
import CodeSource from "!raw-loader!../../../../examples/chatEngine";
# Chat Engine
Chat Engine is a class that allows you to create a chatbot from a retriever. It is a wrapper around a retriever that allows you to chat with it in a conversational manner.
<CodeBlock language="ts">{CodeSource}</CodeBlock>
@@ -0,0 +1,7 @@
---
sidebar_position: 5
---
# More examples
You can check out more examples in the [examples](https://github.com/run-llama/LlamaIndexTS/tree/main/examples) folder of the repository.
@@ -0,0 +1,10 @@
---
sidebar_position: 4
---
import CodeBlock from "@theme/CodeBlock";
import CodeSource from "!raw-loader!../../../../examples/storageContext";
# Save/Load an Index
<CodeBlock language="ts">{CodeSource}</CodeBlock>
+10
View File
@@ -0,0 +1,10 @@
---
sidebar_position: 3
---
import CodeBlock from "@theme/CodeBlock";
import CodeSource from "!raw-loader!../../../../examples/summaryIndex";
# Summary Index
<CodeBlock language="ts">{CodeSource}</CodeBlock>
+10
View File
@@ -0,0 +1,10 @@
---
sidebar_position: 2
---
import CodeBlock from "@theme/CodeBlock";
import CodeSource from "!raw-loader!../../../../examples/vectorIndex";
# Vector Index
<CodeBlock language="ts">{CodeSource}</CodeBlock>
@@ -0,0 +1,2 @@
label: Getting Started
position: 1
@@ -2,7 +2,7 @@
sidebar_position: 3
---
# High-Level Concepts
# Concepts
LlamaIndex.TS helps you build LLM-powered applications (e.g. Q&A, chatbot) over custom data.
@@ -18,7 +18,7 @@ LlamaIndex uses a two stage method when using an LLM with your data:
1. **indexing stage**: preparing a knowledge base, and
2. **querying stage**: retrieving relevant context from the knowledge to assist the LLM in responding to a question
![](./_static/concepts/rag.jpg)
![](../_static/concepts/rag.jpg)
This process is also known as Retrieval Augmented Generation (RAG).
@@ -30,14 +30,14 @@ Let's explore each stage in detail.
LlamaIndex.TS help you prepare the knowledge base with a suite of data connectors and indexes.
![](./_static/concepts/indexing.jpg)
![](../_static/concepts/indexing.jpg)
[**Data Loaders**](./modules/high_level/data_loader.md):
[**Data Loaders**](../modules/data_loader.md):
A data connector (i.e. `Reader`) ingest data from different data sources and data formats into a simple `Document` representation (text and simple metadata).
[**Documents / Nodes**](./modules/high_level/documents_and_nodes.md): A `Document` is a generic container around any data source - for instance, a PDF, an API output, or retrieved data from a database. A `Node` is the atomic unit of data in LlamaIndex and represents a "chunk" of a source `Document`. It's a rich representation that includes metadata and relationships (to other nodes) to enable accurate and expressive retrieval operations.
[**Documents / Nodes**](../modules/documents_and_nodes.md): A `Document` is a generic container around any data source - for instance, a PDF, an API output, or retrieved data from a database. A `Node` is the atomic unit of data in LlamaIndex and represents a "chunk" of a source `Document`. It's a rich representation that includes metadata and relationships (to other nodes) to enable accurate and expressive retrieval operations.
[**Data Indexes**](./modules/high_level/data_index.md):
[**Data Indexes**](../modules/data_index.md):
Once you've ingested your data, LlamaIndex helps you index data into a format that's easy to retrieve.
Under the hood, LlamaIndex parses the raw documents into intermediate representations, calculates vector embeddings, and stores your data in-memory or to disk.
@@ -56,23 +56,23 @@ LlamaIndex provides composable modules that help you build and integrate RAG pip
These building blocks can be customized to reflect ranking preferences, as well as composed to reason over multiple knowledge bases in a structured way.
![](./_static/concepts/querying.jpg)
![](../_static/concepts/querying.jpg)
#### Building Blocks
[**Retrievers**](./modules/low_level/retriever.md):
[**Retrievers**](../modules/retriever.md):
A retriever defines how to efficiently retrieve relevant context from a knowledge base (i.e. index) when given a query.
The specific retrieval logic differs for difference indices, the most popular being dense retrieval against a vector index.
[**Response Synthesizers**](./modules/low_level/response_synthesizer.md):
[**Response Synthesizers**](../modules/response_synthesizer.md):
A response synthesizer generates a response from an LLM, using a user query and a given set of retrieved text chunks.
#### Pipelines
[**Query Engines**](./modules/high_level/query_engine.md):
[**Query Engines**](../modules/query_engine.md):
A query engine is an end-to-end pipeline that allow you to ask question over your data.
It takes in a natural language query, and returns a response, along with reference context retrieved and passed to the LLM.
[**Chat Engines**](./modules/high_level/chat_engine.md):
[**Chat Engines**](../modules/chat_engine.md):
A chat engine is an end-to-end pipeline for having a conversation with your data
(multiple back-and-forth instead of a single question & answer).
@@ -1,5 +1,5 @@
---
sidebar_position: 5
sidebar_position: 2
---
# Environments
@@ -1,5 +1,5 @@
---
sidebar_position: 1
sidebar_position: 0
---
# Installation and Setup
@@ -1,5 +1,5 @@
---
sidebar_position: 2
sidebar_position: 1
---
# Starter Tutorial
+1 -1
View File
@@ -39,7 +39,7 @@ For more complex applications, our lower-level APIs allow advanced users to cust
Our documentation includes [Installation Instructions](./installation.mdx) and a [Starter Tutorial](./starter.md) to build your first application.
Once you're up and running, [High-Level Concepts](./concepts.md) has an overview of LlamaIndex's modular architecture. For more hands-on practical examples, look through our [End-to-End Tutorials](./end_to_end.md).
Once you're up and running, [High-Level Concepts](./getting_started/concepts.md) has an overview of LlamaIndex's modular architecture. For more hands-on practical examples, look through our [End-to-End Tutorials](./end_to_end.md).
## 🗺️ Ecosystem
@@ -1,5 +1,5 @@
---
sidebar_position: 2
sidebar_position: 4
---
# Index
@@ -1,5 +1,5 @@
---
sidebar_position: 1
sidebar_position: 3
---
# Reader / Loader
@@ -0,0 +1,2 @@
label: "Document / Nodes"
position: 0
@@ -1,5 +1,5 @@
---
sidebar_position: 0
sidebar_position: 1
---
# Documents and Nodes
@@ -0,0 +1,45 @@
# Metadata Extraction Usage Pattern
You can use LLMs to automate metadata extraction with our `Metadata Extractor` modules.
Our metadata extractor modules include the following "feature extractors":
- `SummaryExtractor` - automatically extracts a summary over a set of Nodes
- `QuestionsAnsweredExtractor` - extracts a set of questions that each Node can answer
- `TitleExtractor` - extracts a title over the context of each Node by document and combine them
- `KeywordExtractor` - extracts keywords over the context of each Node
Then you can chain the `Metadata Extractors` with the `IngestionPipeline` to extract metadata from a set of documents.
```ts
import {
IngestionPipeline,
TitleExtractor,
QuestionsAnsweredExtractor,
Document,
OpenAI,
} from "llamaindex";
async function main() {
const pipeline = new IngestionPipeline({
transformations: [
new TitleExtractor(),
new QuestionsAnsweredExtractor({
questions: 5,
}),
],
});
const nodes = await pipeline.run({
documents: [
new Document({ text: "I am 10 years old. John is 20 years old." }),
],
});
for (const node of nodes) {
console.log(node.metadata);
}
}
main().then(() => console.log("done"));
```
@@ -1,5 +1,5 @@
---
sidebar_position: 1
sidebar_position: 3
---
# Embedding
@@ -1 +0,0 @@
label: High-Level Modules
-31
View File
@@ -1,31 +0,0 @@
# Core Modules
LlamaIndex.TS offers several core modules, seperated into high-level modules for quickly getting started, and low-level modules for customizing key components as you need.
## High-Level Modules
- [**Document**](./high_level/documents_and_nodes.md): A document represents a text file, PDF file or other contiguous piece of data.
- [**Node**](./high_level/documents_and_nodes.md): The basic data building block. Most commonly, these are parts of the document split into manageable pieces that are small enough to be fed into an embedding model and LLM.
- [**Reader/Loader**](./high_level/data_loader.md): A reader or loader is something that takes in a document in the real world and transforms into a Document class that can then be used in your Index and queries. We currently support plain text files and PDFs with many many more to come.
- [**Indexes**](./high_level/data_index.md): indexes store the Nodes and the embeddings of those nodes.
- [**QueryEngine**](./high_level/query_engine.md): Query engines are what generate the query you put in and give you back the result. Query engines generally combine a pre-built prompt with selected nodes from your Index to give the LLM the context it needs to answer your query.
- [**ChatEngine**](./high_level/chat_engine.md): A ChatEngine helps you build a chatbot that will interact with your Indexes.
## Low Level Module
- [**LLM**](./low_level/llm.md): The LLM class is a unified interface over a large language model provider such as OpenAI GPT-4, Anthropic Claude, or Meta LLaMA. You can subclass it to write a connector to your own large language model.
- [**Embedding**](./low_level/embedding.md): An embedding is represented as a vector of floating point numbers. OpenAI's text-embedding-ada-002 is our default embedding model and each embedding it generates consists of 1,536 floating point numbers. Another popular embedding model is BERT which uses 768 floating point numbers to represent each Node. We provide a number of utilities to work with embeddings including 3 similarity calculation options and Maximum Marginal Relevance
- [**TextSplitter/NodeParser**](./low_level/node_parser.md): Text splitting strategies are incredibly important to the overall efficacy of the embedding search. Currently, while we do have a default, there's no one size fits all solution. Depending on the source documents, you may want to use different splitting sizes and strategies. Currently we support spliltting by fixed size, splitting by fixed size with overlapping sections, splitting by sentence, and splitting by paragraph. The text splitter is used by the NodeParser when splitting `Document`s into `Node`s.
- [**Retriever**](./low_level/retriever.md): The Retriever is what actually chooses the Nodes to retrieve from the index. Here, you may wish to try retrieving more or fewer Nodes per query, changing your similarity function, or creating your own retriever for each individual use case in your application. For example, you may wish to have a separate retriever for code content vs. text content.
- [**ResponseSynthesizer**](./low_level/response_synthesizer.md): The ResponseSynthesizer is responsible for taking a query string, and using a list of `Node`s to generate a response. This can take many forms, like iterating over all the context and refining an answer, or building a tree of summaries and returning the root summary.
- [**Storage**](./low_level/storage.md): At some point you're going to want to store your indexes, data and vectors instead of re-running the embedding models every time. IndexStore, DocStore, VectorStore, and KVStore are abstractions that let you do that. Combined, they form the StorageContext. Currently, we allow you to persist your embeddings in files on the filesystem (or a virtual in memory file system), but we are also actively adding integrations to Vector Databases.
@@ -0,0 +1,2 @@
label: "Ingestion Pipeline"
position: 2
@@ -0,0 +1,99 @@
# Ingestion Pipeline
An `IngestionPipeline` uses a concept of `Transformations` that are applied to input data.
These `Transformations` are applied to your input data, and the resulting nodes are either returned or inserted into a vector database (if given).
## Usage Pattern
The simplest usage is to instantiate an IngestionPipeline like so:
```ts
import fs from "node:fs/promises";
import {
Document,
IngestionPipeline,
MetadataMode,
OpenAIEmbedding,
TitleExtractor,
SimpleNodeParser,
} from "llamaindex";
async function main() {
// Load essay from abramov.txt in Node
const path = "node_modules/llamaindex/examples/abramov.txt";
const essay = await fs.readFile(path, "utf-8");
// Create Document object with essay
const document = new Document({ text: essay, id_: path });
const pipeline = new IngestionPipeline({
transformations: [
new SimpleNodeParser({ chunkSize: 1024, chunkOverlap: 20 }),
new TitleExtractor(),
new OpenAIEmbedding(),
],
});
// run the pipeline
const nodes = await pipeline.run({ documents: [document] });
// print out the result of the pipeline run
for (const node of nodes) {
console.log(node.getContent(MetadataMode.NONE));
}
}
main().catch(console.error);
```
## Connecting to Vector Databases
When running an ingestion pipeline, you can also chose to automatically insert the resulting nodes into a remote vector store.
Then, you can construct an index from that vector store later on.
```ts
import fs from "node:fs/promises";
import {
Document,
IngestionPipeline,
MetadataMode,
OpenAIEmbedding,
TitleExtractor,
SimpleNodeParser,
QdrantVectorStore,
VectorStoreIndex,
} from "llamaindex";
async function main() {
// Load essay from abramov.txt in Node
const path = "node_modules/llamaindex/examples/abramov.txt";
const essay = await fs.readFile(path, "utf-8");
const vectorStore = new QdrantVectorStore({
host: "http://localhost:6333",
});
// Create Document object with essay
const document = new Document({ text: essay, id_: path });
const pipeline = new IngestionPipeline({
transformations: [
new SimpleNodeParser({ chunkSize: 1024, chunkOverlap: 20 }),
new TitleExtractor(),
new OpenAIEmbedding(),
],
vectorStore,
});
// run the pipeline
const nodes = await pipeline.run({ documents: [document] });
// create an index
const index = VectorStoreIndex.fromVectorStore(vectorStore);
}
main().catch(console.error);
```
@@ -0,0 +1,77 @@
# Transformations
A transformation is something that takes a list of nodes as an input, and returns a list of nodes. Each component that implements the Transformatio class has both a `transform` definition responsible for transforming the nodes
Currently, the following components are Transformation objects:
- [SimpleNodeParser](../../api/classes/SimpleNodeParser.md)
- [MetadataExtractor](../documents_and_nodes/metadata_extraction.md)
- Embeddings
## Usage Pattern
While transformations are best used with with an IngestionPipeline, they can also be used directly.
```ts
import { SimpleNodeParser, TitleExtractor, Document } from "llamaindex";
async function main() {
let nodes = new SimpleNodeParser().getNodesFromDocuments([
new Document({ text: "I am 10 years old. John is 20 years old." }),
]);
const titleExtractor = new TitleExtractor();
nodes = await titleExtractor.transform(nodes);
for (const node of nodes) {
console.log(node.getContent(MetadataMode.NONE));
}
}
main().catch(console.error);
```
## Custom Transformations
You can implement any transformation yourself by implementing the `TransformerComponent`.
The following custom transformation will remove any special characters or punctutaion in text.
```ts
import { TransformerComponent, Node } from "llamaindex";
class RemoveSpecialCharacters extends TransformerComponent {
async transform(nodes: Node[]): Promise<Node[]> {
for (const node of nodes) {
node.text = node.text.replace(/[^\w\s]/gi, "");
}
return nodes;
}
}
```
These can then be used directly or in any IngestionPipeline.
```ts
import { IngestionPipeline, Document } from "llamaindex";
async function main() {
const pipeline = new IngestionPipeline({
transformations: [new RemoveSpecialCharacters()],
});
const nodes = await pipeline.run({
documents: [
new Document({ text: "I am 10 years old. John is 20 years old." }),
],
});
for (const node of nodes) {
console.log(node.getContent(MetadataMode.NONE));
}
}
main().catch(console.error);
```
@@ -1,5 +1,5 @@
---
sidebar_position: 0
sidebar_position: 3
---
# LLM
@@ -16,6 +16,18 @@ const openaiLLM = new OpenAI({ model: "gpt-3.5-turbo", temperature: 0 });
const serviceContext = serviceContextFromDefaults({ llm: openaiLLM });
```
## Azure OpenAI
To use Azure OpenAI, you only need to set a few environment variables.
For example:
```
export AZURE_OPENAI_KEY="<YOUR KEY HERE>"
export AZURE_OPENAI_ENDPOINT="<YOUR ENDPOINT, see https://learn.microsoft.com/en-us/azure/ai-services/openai/quickstart?tabs=command-line%2Cpython&pivots=rest-api>"
export AZURE_OPENAI_DEPLOYMENT="gpt-4" # or some other deployment name
```
## API Reference
- [OpenAI](../../api/classes/OpenAI.md)
@@ -1 +0,0 @@
label: Low-Level Modules
@@ -4,7 +4,7 @@ sidebar_position: 3
# NodeParser
The `NodeParser` in LlamaIndex is responbile for splitting `Document` objects into more manageable `Node` objects. When you call `.fromDocuments()`, the `NodeParser` from the `ServiceContext` is used to do this automatically for you. Alternatively, you can use it to split documents ahead of time.
The `NodeParser` in LlamaIndex is responsible for splitting `Document` objects into more manageable `Node` objects. When you call `.fromDocuments()`, the `NodeParser` from the `ServiceContext` is used to do this automatically for you. Alternatively, you can use it to split documents ahead of time.
```typescript
import { Document, SimpleNodeParser } from "llamaindex";
@@ -0,0 +1,2 @@
label: "Query Engines"
position: 2
@@ -1,7 +1,3 @@
---
sidebar_position: 3
---
# QueryEngine
A query engine wraps a `Retriever` and a `ResponseSynthesizer` into a pipeline, that will use the query string to fetech nodes and then send them to the LLM to generate a response.
@@ -0,0 +1,189 @@
# Router Query Engine
In this tutorial, we define a custom router query engine that selects one out of several candidate query engines to execute a query.
## Setup
First, we need to install import the necessary modules from `llamaindex`:
```bash
pnpm i lamaindex
```
```ts
import {
OpenAI,
RouterQueryEngine,
SimpleDirectoryReader,
SimpleNodeParser,
SummaryIndex,
VectorStoreIndex,
serviceContextFromDefaults,
} from "llamaindex";
```
## Loading Data
Next, we need to load some data. We will use the `SimpleDirectoryReader` to load documents from a directory:
```ts
const documents = await new SimpleDirectoryReader().loadData({
directoryPath: "node_modules/llamaindex/examples",
});
```
## Service Context
Next, we need to define some basic rules and parse the documents into nodes. We will use the `SimpleNodeParser` to parse the documents into nodes and `ServiceContext` to define the rules (eg. LLM API key, chunk size, etc.):
```ts
const nodeParser = new SimpleNodeParser({
chunkSize: 1024,
});
const serviceContext = serviceContextFromDefaults({
nodeParser,
llm: new OpenAI(),
});
```
## Creating Indices
Next, we need to create some indices. We will create a `VectorStoreIndex` and a `SummaryIndex`:
```ts
const vectorIndex = await VectorStoreIndex.fromDocuments(documents, {
serviceContext,
});
const summaryIndex = await SummaryIndex.fromDocuments(documents, {
serviceContext,
});
```
## Creating Query Engines
Next, we need to create some query engines. We will create a `VectorStoreQueryEngine` and a `SummaryQueryEngine`:
```ts
const vectorQueryEngine = vectorIndex.asQueryEngine();
const summaryQueryEngine = summaryIndex.asQueryEngine();
```
## Creating a Router Query Engine
Next, we need to create a router query engine. We will use the `RouterQueryEngine` to create a router query engine:
We're defining two query engines, one for summarization and one for retrieving specific context. The router query engine will select the most appropriate query engine based on the query.
```ts
const queryEngine = RouterQueryEngine.fromDefaults({
queryEngineTools: [
{
queryEngine: vectorQueryEngine,
description: "Useful for summarization questions related to Abramov",
},
{
queryEngine: summaryQueryEngine,
description: "Useful for retrieving specific context from Abramov",
},
],
serviceContext,
});
```
## Querying the Router Query Engine
Finally, we can query the router query engine:
```ts
const summaryResponse = await queryEngine.query({
query: "Give me a summary about his past experiences?",
});
console.log({
answer: summaryResponse.response,
metadata: summaryResponse?.metadata?.selectorResult,
});
```
## Full code
```ts
import {
OpenAI,
RouterQueryEngine,
SimpleDirectoryReader,
SimpleNodeParser,
SummaryIndex,
VectorStoreIndex,
serviceContextFromDefaults,
} from "llamaindex";
async function main() {
// Load documents from a directory
const documents = await new SimpleDirectoryReader().loadData({
directoryPath: "node_modules/llamaindex/examples",
});
// Parse the documents into nodes
const nodeParser = new SimpleNodeParser({
chunkSize: 1024,
});
// Create a service context
const serviceContext = serviceContextFromDefaults({
nodeParser,
llm: new OpenAI(),
});
// Create indices
const vectorIndex = await VectorStoreIndex.fromDocuments(documents, {
serviceContext,
});
const summaryIndex = await SummaryIndex.fromDocuments(documents, {
serviceContext,
});
// Create query engines
const vectorQueryEngine = vectorIndex.asQueryEngine();
const summaryQueryEngine = summaryIndex.asQueryEngine();
// Create a router query engine
const queryEngine = RouterQueryEngine.fromDefaults({
queryEngineTools: [
{
queryEngine: vectorQueryEngine,
description: "Useful for summarization questions related to Abramov",
},
{
queryEngine: summaryQueryEngine,
description: "Useful for retrieving specific context from Abramov",
},
],
serviceContext,
});
// Query the router query engine
const summaryResponse = await queryEngine.query({
query: "Give me a summary about his past experiences?",
});
console.log({
answer: summaryResponse.response,
metadata: summaryResponse?.metadata?.selectorResult,
});
const specificResponse = await queryEngine.query({
query: "Tell me about abramov first job?",
});
console.log({
answer: specificResponse.response,
metadata: specificResponse.metadata.selectorResult,
});
}
main().then(() => console.log("Done"));
```
@@ -0,0 +1,2 @@
label: "Vector Stores"
position: 1
@@ -0,0 +1,86 @@
# Qdrant Vector Store
To run this example, you need to have a Qdrant instance running. You can run it with Docker:
```bash
docker pull qdrant/qdrant
docker run -p 6333:6333 qdrant/qdrant
```
## Importing the modules
```ts
import fs from "node:fs/promises";
import { Document, VectorStoreIndex, QdrantVectorStore } from "llamaindex";
```
## Load the documents
```ts
const path = "node_modules/llamaindex/examples/abramov.txt";
const essay = await fs.readFile(path, "utf-8");
```
## Setup Qdrant
```ts
const vectorStore = new QdrantVectorStore({
url: "http://localhost:6333",
});
```
## Setup the index
```ts
const document = new Document({ text: essay, id_: path });
const index = await VectorStoreIndex.fromDocuments([document], {
vectorStore,
});
```
## Query the index
```ts
const queryEngine = index.asQueryEngine();
const response = await queryEngine.query({
query: "What did the author do in college?",
});
// Output response
console.log(response.toString());
```
## Full code
```ts
import fs from "node:fs/promises";
import { Document, VectorStoreIndex, QdrantVectorStore } from "llamaindex";
async function main() {
const path = "node_modules/llamaindex/examples/abramov.txt";
const essay = await fs.readFile(path, "utf-8");
const vectorStore = new QdrantVectorStore({
url: "http://localhost:6333",
});
const document = new Document({ text: essay, id_: path });
const index = await VectorStoreIndex.fromDocuments([document], {
vectorStore,
});
const queryEngine = index.asQueryEngine();
const response = await queryEngine.query({
query: "What did the author do in college?",
});
// Output response
console.log(response.toString());
}
main().catch(console.error);
```
@@ -1 +1,2 @@
label: Observability
position: 5
@@ -41,7 +41,7 @@ LlamaIndex.TS هو إطار بيانات لتطبيقات LLM لاستيعاب
تتضمن وثائقنا [تعليمات التثبيت](./installation.mdx) و[دليل البداية](./starter.md) لبناء تطبيقك الأول.
بمجرد أن تكون جاهزًا وتعمل ، يحتوي [مفاهيم عالية المستوى](./concepts.md) على نظرة عامة على الهندسة المعمارية المتعددة المستويات لـ LlamaIndex. لمزيد من الأمثلة العملية التفصيلية ، يمكنك الاطلاع على [دروس النهاية إلى النهاية](./end_to_end.md).
بمجرد أن تكون جاهزًا وتعمل ، يحتوي [مفاهيم عالية المستوى](./getting_started/concepts.md) على نظرة عامة على الهندسة المعمارية المتعددة المستويات لـ LlamaIndex. لمزيد من الأمثلة العملية التفصيلية ، يمكنك الاطلاع على [دروس النهاية إلى النهاية](./end_to_end.md).
## 🗺️ النظام البيئي
@@ -43,7 +43,7 @@ LlamaIndex.TS предоставя основен набор от инструм
Документацията ни включва [Инструкции за инсталиране](./installation.mdx) и [Урок за начинаещи](./starter.md), за да построите първото си приложение.
След като сте готови, [Високо ниво концепции](./concepts.md) представя общ преглед на модулната архитектура на LlamaIndex. За повече практически примери, разгледайте нашите [Уроци от начало до край](./end_to_end.md).
След като сте готови, [Високо ниво концепции](./getting_started/concepts.md) представя общ преглед на модулната архитектура на LlamaIndex. За повече практически примери, разгледайте нашите [Уроци от начало до край](./end_to_end.md).
## 🗺️ Екосистема
@@ -41,7 +41,7 @@ Per a aplicacions més complexes, les nostres API de nivell inferior permeten al
La nostra documentació inclou [Instruccions d'Instal·lació](./installation.mdx) i un [Tutorial d'Inici](./starter.md) per a construir la vostra primera aplicació.
Un cop tingueu tot a punt, [Conceptes de Nivell Alt](./concepts.md) ofereix una visió general de l'arquitectura modular de LlamaIndex. Per a més exemples pràctics, consulteu els nostres [Tutorials de Principi a Fi](./end_to_end.md).
Un cop tingueu tot a punt, [Conceptes de Nivell Alt](./getting_started/concepts.md) ofereix una visió general de l'arquitectura modular de LlamaIndex. Per a més exemples pràctics, consulteu els nostres [Tutorials de Principi a Fi](./end_to_end.md).
## 🗺️ Ecosistema
@@ -41,7 +41,7 @@ Pro složitější aplikace naše API na nižší úrovni umožňuje pokročilý
Naše dokumentace obsahuje [Návod k instalaci](./installation.mdx) a [Úvodní tutoriál](./starter.md) pro vytvoření vaší první aplikace.
Jakmile jste připraveni, [Vysokoúrovňové koncepty](./concepts.md) poskytují přehled o modulární architektuře LlamaIndexu. Pro více praktických příkladů se podívejte na naše [Tutoriály od začátku do konce](./end_to_end.md).
Jakmile jste připraveni, [Vysokoúrovňové koncepty](./getting_started/concepts.md) poskytují přehled o modulární architektuře LlamaIndexu. Pro více praktických příkladů se podívejte na naše [Tutoriály od začátku do konce](./end_to_end.md).
## 🗺️ Ekosystém
@@ -41,7 +41,7 @@ Til mere komplekse applikationer giver vores API'er på lavere niveau avancerede
Vores dokumentation inkluderer [Installationsinstruktioner](./installation.mdx) og en [Starter Tutorial](./starter.md) til at bygge din første applikation.
Når du er i gang, giver [Højniveaukoncepter](./concepts.md) et overblik over LlamaIndex's modulære arkitektur. For flere praktiske eksempler, kan du kigge igennem vores [End-to-End Tutorials](./end_to_end.md).
Når du er i gang, giver [Højniveaukoncepter](./getting_started/concepts.md) et overblik over LlamaIndex's modulære arkitektur. For flere praktiske eksempler, kan du kigge igennem vores [End-to-End Tutorials](./end_to_end.md).
## 🗺️ Økosystem
@@ -41,7 +41,7 @@ Für komplexere Anwendungen ermöglichen unsere APIs auf niedrigerer Ebene fortg
Unsere Dokumentation enthält [Installationsanweisungen](./installation.mdx) und ein [Einführungstutorial](./starter.md), um Ihre erste Anwendung zu erstellen.
Sobald Sie bereit sind, bietet [High-Level-Konzepte](./concepts.md) einen Überblick über die modulare Architektur von LlamaIndex. Für praktische Beispiele schauen Sie sich unsere [End-to-End-Tutorials](./end_to_end.md) an.
Sobald Sie bereit sind, bietet [High-Level-Konzepte](./getting_started/concepts.md) einen Überblick über die modulare Architektur von LlamaIndex. Für praktische Beispiele schauen Sie sich unsere [End-to-End-Tutorials](./end_to_end.md) an.
## 🗺️ Ökosystem
@@ -43,7 +43,7 @@ slug: /
Η τεκμηρίωσή μας περιλαμβάνει [Οδηγίες Εγκατάστασης](./installation.mdx) και ένα [Εισαγωγικό Εκπαιδευτικό Πρόγραμμα](./starter.md) για να δημιουργήσετε την πρώτη σας εφαρμογή.
Αφού ξεκινήσετε, οι [Υψηλού Επιπέδου Έννοιες](./concepts.md) παρέχουν μια επισκόπηση της μοντουλαρισμένης αρχιτεκτονικής του LlamaIndex. Για περισσότερα πρακτικά παραδείγματα, ρίξτε μια ματιά στα [Ολοκληρωμένα Εκπαιδευτικά Προγράμματα](./end_to_end.md).
Αφού ξεκινήσετε, οι [Υψηλού Επιπέδου Έννοιες](./getting_started/concepts.md) παρέχουν μια επισκόπηση της μοντουλαρισμένης αρχιτεκτονικής του LlamaIndex. Για περισσότερα πρακτικά παραδείγματα, ρίξτε μια ματιά στα [Ολοκληρωμένα Εκπαιδευτικά Προγράμματα](./end_to_end.md).
## 🗺️ Οικοσύστημα
@@ -41,7 +41,7 @@ Para aplicaciones más complejas, nuestras API de nivel inferior permiten a los
Nuestra documentación incluye [Instrucciones de instalación](./installation.mdx) y un [Tutorial de inicio](./starter.md) para construir tu primera aplicación.
Una vez que estés en funcionamiento, [Conceptos de alto nivel](./concepts.md) ofrece una visión general de la arquitectura modular de LlamaIndex. Para obtener ejemplos prácticos más detallados, consulta nuestros [Tutoriales de extremo a extremo](./end_to_end.md).
Una vez que estés en funcionamiento, [Conceptos de alto nivel](./getting_started/concepts.md) ofrece una visión general de la arquitectura modular de LlamaIndex. Para obtener ejemplos prácticos más detallados, consulta nuestros [Tutoriales de extremo a extremo](./end_to_end.md).
## 🗺️ Ecosistema
@@ -41,7 +41,7 @@ Täpsemate rakenduste jaoks võimaldavad meie madalama taseme API-d edasijõudnu
Meie dokumentatsioonis on [paigaldusjuhised](./installation.mdx) ja [algõpetus](./starter.md) oma esimese rakenduse loomiseks.
Kui olete valmis ja töötate, siis [kõrgtasemel kontseptsioonid](./concepts.md) annavad ülevaate LlamaIndexi moodularhitektuurist. Praktiliste näidete jaoks vaadake läbi meie [otsast lõpuni õpetused](./end_to_end.md).
Kui olete valmis ja töötate, siis [kõrgtasemel kontseptsioonid](./getting_started/concepts.md) annavad ülevaate LlamaIndexi moodularhitektuurist. Praktiliste näidete jaoks vaadake läbi meie [otsast lõpuni õpetused](./end_to_end.md).
## 🗺️ Ökosüsteem
@@ -43,7 +43,7 @@ API سطح بالای ما به کاربران مبتدی امکان استفا
مستندات ما شامل [دستورالعمل نصب](./installation.mdx) و [آموزش شروع کار](./starter.md) برای ساخت اولین برنامه شما است.
با راه اندازی و اجرا شدن، [مفاهیم سطح بالا](./concepts.md) یک نمای کلی از معماری ماژولار لاماایندکس را ارائه می دهد. برای مثال های عملی بیشتر، به [آموزش های پایان به پایان](./end_to_end.md) مراجعه کنید.
با راه اندازی و اجرا شدن، [مفاهیم سطح بالا](./getting_started/concepts.md) یک نمای کلی از معماری ماژولار لاماایندکس را ارائه می دهد. برای مثال های عملی بیشتر، به [آموزش های پایان به پایان](./end_to_end.md) مراجعه کنید.
"
@@ -43,7 +43,7 @@ Monimutkaisempiin sovelluksiin tarjoamme matalamman tason API:t, jotka mahdollis
Dokumentaatiostamme löydät [asennusohjeet](./installation.mdx) ja [aloitusopetusohjelman](./starter.md) ensimmäisen sovelluksesi rakentamiseen.
Kun olet päässyt vauhtiin, [Korkean tason käsitteet](./concepts.md) antaa yleiskuvan LlamaIndexin modulaarisesta arkkitehtuurista. Lisää käytännön esimerkkejä löydät [Päästä päähän -opetusohjelmista](./end_to_end.md).
Kun olet päässyt vauhtiin, [Korkean tason käsitteet](./getting_started/concepts.md) antaa yleiskuvan LlamaIndexin modulaarisesta arkkitehtuurista. Lisää käytännön esimerkkejä löydät [Päästä päähän -opetusohjelmista](./end_to_end.md).
## 🗺️ Ekosysteemi
@@ -43,7 +43,7 @@ API הרמה הגבוהה שלנו מאפשר למשתמשים מתחילים ל
התיעוד שלנו כולל [הוראות התקנה](./installation.mdx) ו[מדריך התחלה](./starter.md) לבניית היישום הראשון שלך.
כאשר אתה מוכן ורץ, [מושגים ברמה גבוהה](./concepts.md) מציג סקירה על ארכיטקטורה מודולרית של LlamaIndex. לדוגמאות פרקטיות יותר, עיין ב[מדריכים מתקדמים מתחילה ועד סוף](./end_to_end.md).
כאשר אתה מוכן ורץ, [מושגים ברמה גבוהה](./getting_started/concepts.md) מציג סקירה על ארכיטקטורה מודולרית של LlamaIndex. לדוגמאות פרקטיות יותר, עיין ב[מדריכים מתקדמים מתחילה ועד סוף](./end_to_end.md).
"
@@ -43,7 +43,7 @@ LlamaIndex.TS जावास्क्रिप्ट और TypeScript के
हमारी दस्तावेज़ी में [स्थापना निर्देश](./installation.mdx) और [स्टार्टर ट्यूटोरियल](./starter.md) शामिल हैं, जिनका उपयोग करके आप अपना पहला एप्लिकेशन बना सकते हैं।
एक बार जब आप शुरू हो जाएं, [उच्च स्तरीय अवधारणाएँ](./concepts.md) में LlamaIndex की मॉड्यूलर आर्किटेक्चर का अवलोकन है। अधिक हैंड्स-ऑन प्रैक्टिकल उदाहरणों के लिए, हमारे [एंड-टू-एंड ट्यूटोरियल](./end_to_end.md) को देखें।
एक बार जब आप शुरू हो जाएं, [उच्च स्तरीय अवधारणाएँ](./getting_started/concepts.md) में LlamaIndex की मॉड्यूलर आर्किटेक्चर का अवलोकन है। अधिक हैंड्स-ऑन प्रैक्टिकल उदाहरणों के लिए, हमारे [एंड-टू-एंड ट्यूटोरियल](./end_to_end.md) को देखें।
"
@@ -41,7 +41,7 @@ Za složenije aplikacije, naše API-je niže razine omogućuju naprednim korisni
Naša dokumentacija uključuje [Upute za instalaciju](./installation.mdx) i [Uvodni vodič](./starter.md) za izgradnju vaše prve aplikacije.
Kada ste spremni za rad, [Visokorazinski koncepti](./concepts.md) pružaju pregled modularne arhitekture LlamaIndex-a. Za praktične primjere, pogledajte naše [Vodiče od početka do kraja](./end_to_end.md).
Kada ste spremni za rad, [Visokorazinski koncepti](./getting_started/concepts.md) pružaju pregled modularne arhitekture LlamaIndex-a. Za praktične primjere, pogledajte naše [Vodiče od početka do kraja](./end_to_end.md).
## 🗺️ Ekosustav
@@ -41,7 +41,7 @@ A komplexebb alkalmazásokhoz a mélyebb szintű API-k lehetővé teszik a halad
A dokumentációnk tartalmazza a [Telepítési utasításokat](./installation.mdx) és egy [Kezdő útmutatót](./starter.md) az első alkalmazás létrehozásához.
Miután elindultál, a [Magas szintű fogalmak](./concepts.md) áttekintést ad a LlamaIndex moduláris architektúrájáról. További gyakorlati példákért tekintsd meg az [End-to-End útmutatóinkat](./end_to_end.md).
Miután elindultál, a [Magas szintű fogalmak](./getting_started/concepts.md) áttekintést ad a LlamaIndex moduláris architektúrájáról. További gyakorlati példákért tekintsd meg az [End-to-End útmutatóinkat](./end_to_end.md).
## 🗺️ Ökoszisztéma
@@ -41,7 +41,7 @@ Untuk aplikasi yang lebih kompleks, API tingkat lebih rendah kami memungkinkan p
Dokumentasi kami mencakup [Instruksi Instalasi](./installation.mdx) dan [Tutorial Awal](./starter.md) untuk membangun aplikasi pertama Anda.
Setelah Anda mulai, [Konsep Tingkat Tinggi](./concepts.md) memberikan gambaran tentang arsitektur modular LlamaIndex. Untuk contoh praktis yang lebih mendalam, lihat [Tutorial End-to-End](./end_to_end.md).
Setelah Anda mulai, [Konsep Tingkat Tinggi](./getting_started/concepts.md) memberikan gambaran tentang arsitektur modular LlamaIndex. Untuk contoh praktis yang lebih mendalam, lihat [Tutorial End-to-End](./end_to_end.md).
## 🗺️ Ekosistem
@@ -41,7 +41,7 @@ Per applicazioni più complesse, le nostre API di livello inferiore consentono a
La nostra documentazione include le [Istruzioni di installazione](./installation.mdx) e un [Tutorial introduttivo](./starter.md) per creare la tua prima applicazione.
Una volta che sei pronto, i [Concetti di alto livello](./concepts.md) offrono una panoramica dell'architettura modulare di LlamaIndex. Per ulteriori esempi pratici, consulta i nostri [Tutorial end-to-end](./end_to_end.md).
Una volta che sei pronto, i [Concetti di alto livello](./getting_started/concepts.md) offrono una panoramica dell'architettura modulare di LlamaIndex. Per ulteriori esempi pratici, consulta i nostri [Tutorial end-to-end](./end_to_end.md).
## 🗺️ Ecosistema
@@ -41,7 +41,7 @@ LlamaIndex.TSは、JavaScriptとTypeScriptを使用してLLMアプリを構築
私たちのドキュメントには、[インストール手順](./installation.mdx)と[スターターチュートリアル](./starter.md)が含まれており、最初のアプリケーションの構築をサポートします。
一度準備ができたら、[ハイレベルなコンセプト](./concepts.md)では、LlamaIndexのモジュラーアーキテクチャの概要を説明しています。より実践的な例については、[エンドツーエンドのチュートリアル](./end_to_end.md)を参照してください。
一度準備ができたら、[ハイレベルなコンセプト](./getting_started/concepts.md)では、LlamaIndexのモジュラーアーキテクチャの概要を説明しています。より実践的な例については、[エンドツーエンドのチュートリアル](./end_to_end.md)を参照してください。
## 🗺️ エコシステム
@@ -41,7 +41,7 @@ LlamaIndex.TS는 JavaScript와 TypeScript로 LLM 앱을 개발하는 모든 사
저희 문서에는 [설치 지침](./installation.mdx)과 [스타터 튜토리얼](./starter.md)이 포함되어 있어 첫 번째 애플리케이션을 빌드할 수 있습니다.
한 번 시작하면, [고수준 개념](./concepts.md)에서 LlamaIndex의 모듈식 아키텍처에 대한 개요를 확인할 수 있습니다. 더 많은 실전 예제를 원하신다면, [End-to-End 튜토리얼](./end_to_end.md)을 참조해주세요.
한 번 시작하면, [고수준 개념](./getting_started/concepts.md)에서 LlamaIndex의 모듈식 아키텍처에 대한 개요를 확인할 수 있습니다. 더 많은 실전 예제를 원하신다면, [End-to-End 튜토리얼](./end_to_end.md)을 참조해주세요.
"
@@ -41,7 +41,7 @@ Sudėtingesnėms programoms mūsų žemesnio lygio API leidžia pažengusiems na
Mūsų dokumentacija apima [įdiegimo instrukcijas](./installation.mdx) ir [pradžios vadovą](./starter.md), skirtą sukurti pirmąją aplikaciją.
Kai jau esate paleidę, [aukšto lygio konceptai](./concepts.md) pateikia apžvalgą apie LlamaIndex modularią architektūrą. Norėdami gauti daugiau praktinių pavyzdžių, peržiūrėkite mūsų [nuo pradžių iki pabaigos vadovus](./end_to_end.md).
Kai jau esate paleidę, [aukšto lygio konceptai](./getting_started/concepts.md) pateikia apžvalgą apie LlamaIndex modularią architektūrą. Norėdami gauti daugiau praktinių pavyzdžių, peržiūrėkite mūsų [nuo pradžių iki pabaigos vadovus](./end_to_end.md).
## 🗺️ Ekosistema
@@ -43,7 +43,7 @@ Lielākām un sarežģītākām lietojumprogrammām mūsu zemāka līmeņa API
Mūsu dokumentācijā ir iekļautas [Instalācijas instrukcijas](./installation.mdx) un [Sākuma pamācība](./starter.md), lai izveidotu savu pirmo lietojumprogrammu.
Kad esat gatavs, [Augsta līmeņa koncepti](./concepts.md) sniedz pārskatu par LlamaIndex modulāro arhitektūru. Lai iegūtu vairāk praktisku piemēru, apskatiet mūsu [Galēji līdz galam pamācības](./end_to_end.md).
Kad esat gatavs, [Augsta līmeņa koncepti](./getting_started/concepts.md) sniedz pārskatu par LlamaIndex modulāro arhitektūru. Lai iegūtu vairāk praktisku piemēru, apskatiet mūsu [Galēji līdz galam pamācības](./end_to_end.md).
## 🗺️ Ekosistēma
@@ -41,7 +41,7 @@ Voor complexere toepassingen stellen onze API's op lager niveau gevorderde gebru
Onze documentatie bevat [Installatie-instructies](./installation.mdx) en een [Starterzelfstudie](./starter.md) om uw eerste toepassing te bouwen.
Zodra u aan de slag bent, geeft [Hoog-niveau Concepten](./concepts.md) een overzicht van de modulaire architectuur van LlamaIndex. Voor meer praktische voorbeelden kunt u onze [End-to-End Tutorials](./end_to_end.md) bekijken.
Zodra u aan de slag bent, geeft [Hoog-niveau Concepten](./getting_started/concepts.md) een overzicht van de modulaire architectuur van LlamaIndex. Voor meer praktische voorbeelden kunt u onze [End-to-End Tutorials](./end_to_end.md) bekijken.
## 🗺️ Ecosysteem
@@ -41,7 +41,7 @@ For mer komplekse applikasjoner lar våre lavnivå-APIer avanserte brukere tilpa
Dokumentasjonen vår inkluderer [Installasjonsinstruksjoner](./installation.mdx) og en [Starterveiledning](./starter.md) for å bygge din første applikasjon.
Når du er oppe og kjører, gir [Høynivåkonsepter](./concepts.md) en oversikt over LlamaIndex sin modulære arkitektur. For mer praktiske eksempler, kan du se gjennom våre [End-to-End veiledninger](./end_to_end.md).
Når du er oppe og kjører, gir [Høynivåkonsepter](./getting_started/concepts.md) en oversikt over LlamaIndex sin modulære arkitektur. For mer praktiske eksempler, kan du se gjennom våre [End-to-End veiledninger](./end_to_end.md).
## 🗺️ Økosystem
@@ -41,7 +41,7 @@ Dla bardziej zaawansowanych aplikacji nasze API na niższym poziomie umożliwia
Nasza dokumentacja zawiera [Instrukcje instalacji](./installation.mdx) oraz [Samouczek dla początkujących](./starter.md), który pomoże Ci zbudować swoją pierwszą aplikację.
Gdy już będziesz gotowy, [Wysokopoziomowe koncepcje](./concepts.md) zawierają przegląd modułowej architektury LlamaIndex. Jeśli chcesz zobaczyć praktyczne przykłady, zapoznaj się z naszymi [Samouczkami od początku do końca](./end_to_end.md).
Gdy już będziesz gotowy, [Wysokopoziomowe koncepcje](./getting_started/concepts.md) zawierają przegląd modułowej architektury LlamaIndex. Jeśli chcesz zobaczyć praktyczne przykłady, zapoznaj się z naszymi [Samouczkami od początku do końca](./end_to_end.md).
## 🗺️ Ekosystem
@@ -41,7 +41,7 @@ Para aplicativos mais complexos, nossas APIs de nível inferior permitem que usu
Nossa documentação inclui [Instruções de Instalação](./installation.mdx) e um [Tutorial Inicial](./starter.md) para construir seu primeiro aplicativo.
Depois de estar pronto para começar, [Conceitos de Alto Nível](./concepts.md) oferece uma visão geral da arquitetura modular do LlamaIndex. Para exemplos práticos mais detalhados, consulte nossos [Tutoriais de Ponta a Ponta](./end_to_end.md).
Depois de estar pronto para começar, [Conceitos de Alto Nível](./getting_started/concepts.md) oferece uma visão geral da arquitetura modular do LlamaIndex. Para exemplos práticos mais detalhados, consulte nossos [Tutoriais de Ponta a Ponta](./end_to_end.md).
## 🗺️ Ecossistema
@@ -41,7 +41,7 @@ Pentru aplicații mai complexe, API-urile noastre de nivel inferior permit utili
Documentația noastră include [Instrucțiuni de instalare](./installation.mdx) și un [Tutorial de pornire](./starter.md) pentru a construi prima ta aplicație.
Odată ce ai început, [Concepte de nivel înalt](./concepts.md) oferă o prezentare generală a arhitecturii modulare a LlamaIndex. Pentru mai multe exemple practice, consultă [Tutorialele de la cap la coadă](./end_to_end.md).
Odată ce ai început, [Concepte de nivel înalt](./getting_started/concepts.md) oferă o prezentare generală a arhitecturii modulare a LlamaIndex. Pentru mai multe exemple practice, consultă [Tutorialele de la cap la coadă](./end_to_end.md).
## 🗺️ Ecosistem
@@ -41,7 +41,7 @@ LlamaIndex.TS предоставляет основной набор инстр
Наша документация включает [Инструкции по установке](./installation.mdx) и [Стартовое руководство](./starter.md) для создания вашего первого приложения.
Когда вы начнете работу, [Высокоуровневые концепции](./concepts.md) предоставляют обзор модульной архитектуры LlamaIndex. Для более практических примеров руководство [Полный цикл руководств](./end_to_end.md) будет полезно.
Когда вы начнете работу, [Высокоуровневые концепции](./getting_started/concepts.md) предоставляют обзор модульной архитектуры LlamaIndex. Для более практических примеров руководство [Полный цикл руководств](./end_to_end.md) будет полезно.
## 🗺️ Экосистема
@@ -41,7 +41,7 @@ Za složenije aplikacije, naše API-je na nižem nivou omogućavaju naprednim ko
Naša dokumentacija uključuje [Uputstva za instalaciju](./installation.mdx) i [Uvodni tutorijal](./starter.md) za izgradnju vaše prve aplikacije.
Kada ste spremni za rad, [Koncepti na visokom nivou](./concepts.md) pružaju pregled modularne arhitekture LlamaIndex-a. Za praktične primere, pogledajte naše [Vodiče od početka do kraja](./end_to_end.md).
Kada ste spremni za rad, [Koncepti na visokom nivou](./getting_started/concepts.md) pružaju pregled modularne arhitekture LlamaIndex-a. Za praktične primere, pogledajte naše [Vodiče od početka do kraja](./end_to_end.md).
## 🗺️ Ekosistem
@@ -41,7 +41,7 @@ Za bolj kompleksne aplikacije naša nizkonivojska API omogoča naprednim uporabn
Naša dokumentacija vključuje [Navodila za namestitev](./installation.mdx) in [Vodič za začetek](./starter.md), ki vam pomagata zgraditi vašo prvo aplikacijo.
Ko ste pripravljeni, [Visokonivojski koncepti](./concepts.md) ponujajo pregled modularne arhitekture LlamaIndex-a. Za več praktičnih primerov si oglejte naše [Vodiče od začetka do konca](./end_to_end.md).
Ko ste pripravljeni, [Visokonivojski koncepti](./getting_started/concepts.md) ponujajo pregled modularne arhitekture LlamaIndex-a. Za več praktičnih primerov si oglejte naše [Vodiče od začetka do konca](./end_to_end.md).
## 🗺️ Ekosistem
@@ -41,7 +41,7 @@ Pre zložitejšie aplikácie naša nižšia úroveň API umožňuje pokročilým
Naša dokumentácia obsahuje [Inštalačné pokyny](./installation.mdx) a [Úvodný tutoriál](./starter.md) pre vytvorenie vašej prvej aplikácie.
Keď už máte všetko pripravené, [Vysokoúrovňové koncepty](./concepts.md) poskytujú prehľad o modulárnej architektúre LlamaIndexu. Pre viac praktických príkladov si prečítajte naše [Tutoriály od začiatku do konca](./end_to_end.md).
Keď už máte všetko pripravené, [Vysokoúrovňové koncepty](./getting_started/concepts.md) poskytujú prehľad o modulárnej architektúre LlamaIndexu. Pre viac praktických príkladov si prečítajte naše [Tutoriály od začiatku do konca](./end_to_end.md).
## 🗺️ Ekosystém
@@ -41,7 +41,7 @@ För mer komplexa applikationer tillåter våra lägre nivå-API:er avancerade a
Vår dokumentation inkluderar [Installationsinstruktioner](./installation.mdx) och en [Starterhandledning](./starter.md) för att bygga din första applikation.
När du är igång, ger [Högnivåkoncept](./concepts.md) en översikt över LlamaIndex modulära arkitektur. För mer praktiska exempel, titta igenom våra [Steg-för-steg handledningar](./end_to_end.md).
När du är igång, ger [Högnivåkoncept](./getting_started/concepts.md) en översikt över LlamaIndex modulära arkitektur. För mer praktiska exempel, titta igenom våra [Steg-för-steg handledningar](./end_to_end.md).
## 🗺️ Ekosystem
@@ -41,7 +41,7 @@ API ระดับสูงของเราช่วยให้ผู้ใ
เอกสารของเราประกอบด้วย[คำแนะนำการติดตั้ง](./installation.mdx)และ[บทแนะนำเบื้องต้น](./starter.md)เพื่อสร้างแอปพลิเคชันครั้งแรกของคุณ
เมื่อคุณเริ่มใช้งานแล้ว [แนวคิดระดับสูง](./concepts.md) มีภาพรวมของสถาปัตยกรรมแบบโมดูลของ LlamaIndex สำหรับตัวอย่างที่เป็นปฏิบัติจริงมากขึ้น โปรดดูที่ [บทแนะนำจบสู่จบ](./end_to_end.md) เพื่อตัวอย่างที่ใช้งานได้จริง
เมื่อคุณเริ่มใช้งานแล้ว [แนวคิดระดับสูง](./getting_started/concepts.md) มีภาพรวมของสถาปัตยกรรมแบบโมดูลของ LlamaIndex สำหรับตัวอย่างที่เป็นปฏิบัติจริงมากขึ้น โปรดดูที่ [บทแนะนำจบสู่จบ](./end_to_end.md) เพื่อตัวอย่างที่ใช้งานได้จริง
"
@@ -43,7 +43,7 @@ Daha karmaşık uygulamalar için, düşük seviyeli API'larımız, gelişmiş k
Dökümantasyonumuz, [Kurulum Talimatları](./installation.mdx) ve ilk uygulamanızı oluşturmanız için bir [Başlangıç Kılavuzu](./starter.md) içerir.
Çalışmaya başladıktan sonra, [Yüksek Düzeyli Kavramlar](./concepts.md) LlamaIndex'in modüler mimarisinin bir genel bakışını sunar. Daha fazla pratik örnek için [Uçtan Uca Öğreticilerimize](./end_to_end.md) göz atabilirsiniz.
Çalışmaya başladıktan sonra, [Yüksek Düzeyli Kavramlar](./getting_started/concepts.md) LlamaIndex'in modüler mimarisinin bir genel bakışını sunar. Daha fazla pratik örnek için [Uçtan Uca Öğreticilerimize](./end_to_end.md) göz atabilirsiniz.
## 🗺️ Ekosistem
@@ -41,7 +41,7 @@ LlamaIndex.TS надає основний набір інструментів,
Наша документація містить [Інструкції з встановлення](./installation.mdx) та [Посібник для початківців](./starter.md) для створення вашої першої програми.
Після того, як ви розпочнете роботу, [Високорівневі концепції](./concepts.md) містить огляд модульної архітектури LlamaIndex. Для більш практичних прикладів роботи, перегляньте наші [Посібники з кінця в кінець](./end_to_end.md).
Після того, як ви розпочнете роботу, [Високорівневі концепції](./getting_started/concepts.md) містить огляд модульної архітектури LlamaIndex. Для більш практичних прикладів роботи, перегляньте наші [Посібники з кінця в кінець](./end_to_end.md).
## 🗺️ Екосистема
@@ -41,7 +41,7 @@ API cấp cao của chúng tôi cho phép người dùng mới bắt đầu sử
Tài liệu của chúng tôi bao gồm [Hướng dẫn cài đặt](./installation.mdx) và [Hướng dẫn bắt đầu](./starter.md) để xây dựng ứng dụng đầu tiên của bạn.
Khi bạn đã sẵn sàng, [Khái niệm cấp cao](./concepts.md) cung cấp một cái nhìn tổng quan về kiến trúc mô-đun của LlamaIndex. Để có thêm ví dụ thực tế, hãy xem qua [Hướng dẫn từ đầu đến cuối](./end_to_end.md).
Khi bạn đã sẵn sàng, [Khái niệm cấp cao](./getting_started/concepts.md) cung cấp một cái nhìn tổng quan về kiến trúc mô-đun của LlamaIndex. Để có thêm ví dụ thực tế, hãy xem qua [Hướng dẫn từ đầu đến cuối](./end_to_end.md).
## 🗺️ Hệ sinh thái
@@ -39,7 +39,7 @@ LlamaIndex.TS 提供了一套核心工具,对于任何使用JavaScript和TypeS
我们的文档包括[安装说明](./installation.mdx)和一个[入门教程](./starter.md),帮助你构建第一个应用程序。
一旦你开始运行,[高级概念](./concepts.md)有一个LlamaIndex模块化架构的概览。更多实践例子,请浏览我们的[端到端教程](./end_to_end.md)。
一旦你开始运行,[高级概念](./getting_started/concepts.md)有一个LlamaIndex模块化架构的概览。更多实践例子,请浏览我们的[端到端教程](./end_to_end.md)。
## 🗺️ 生态系统
@@ -41,7 +41,7 @@ LlamaIndex.TS 提供了一組核心工具,對於使用 JavaScript 和 TypeScri
我們的文檔包括[安裝說明](./installation.mdx)和[入門教程](./starter.md),以構建您的第一個應用程序。
一旦您開始運行,[高級概念](./concepts.md)提供了 LlamaIndex 模塊化架構的概述。如果需要更多實際的操作示例,請查看我們的[端到端教程](./end_to_end.md)。
一旦您開始運行,[高級概念](./getting_started/concepts.md)提供了 LlamaIndex 模塊化架構的概述。如果需要更多實際的操作示例,請查看我們的[端到端教程](./end_to_end.md)。
## 🗺️ 生態系統
+7 -7
View File
@@ -1,6 +1,6 @@
{
"name": "docs",
"version": "0.0.0",
"version": "0.0.1",
"private": true,
"scripts": {
"docusaurus": "docusaurus",
@@ -15,8 +15,8 @@
"typecheck": "tsc"
},
"dependencies": {
"@docusaurus/core": "^3.1.0",
"@docusaurus/remark-plugin-npm2yarn": "^3.1.0",
"@docusaurus/core": "^3.1.1",
"@docusaurus/remark-plugin-npm2yarn": "^3.1.1",
"@mdx-js/react": "^3.0.0",
"clsx": "^2.1.0",
"postcss": "^8.4.33",
@@ -27,11 +27,11 @@
},
"devDependencies": {
"@docusaurus/module-type-aliases": "3.1.0",
"@docusaurus/preset-classic": "^3.1.0",
"@docusaurus/theme-classic": "^3.1.0",
"@docusaurus/types": "^3.1.0",
"@docusaurus/preset-classic": "^3.1.1",
"@docusaurus/theme-classic": "^3.1.1",
"@docusaurus/types": "^3.1.1",
"@tsconfig/docusaurus": "^2.0.2",
"@types/node": "^18.19.6",
"@types/node": "^18.19.10",
"docusaurus-plugin-typedoc": "^0.22.0",
"typedoc": "^0.25.7",
"typedoc-plugin-markdown": "^3.17.1",
-22
View File
@@ -1,22 +0,0 @@
# simple
## 0.0.3
### Patch Changes
- Updated dependencies [5a765aa]
- llamaindex@0.0.5
## 0.0.2
### Patch Changes
- Updated dependencies [c65d671]
- llamaindex@0.0.4
## 0.0.1
### Patch Changes
- Updated dependencies [ca9410f]
- llamaindex@0.0.3
+12 -22
View File
@@ -1,29 +1,19 @@
# Simple Examples
# LlamaIndexTS Examples
Before running any of the examples, make sure to set your OpenAI environment variable:
Before running any of the code examples,
make sure you have basic knowledge of the [LlamaIndexTS](https://ts.llamaindex.ai/).
```bash
## Usage
```shell
# export your API key
export OPENAI_API_KEY="sk-..."
npx ts-node ./chatEngine.ts
```
There are two ways to run the examples, using the latest published version of `llamaindex` or using a local build.
## Build your own RAG app
## Using the latest published version
Make sure to call `npm install` before running these examples:
```bash
npm install
```shell
npx create llama
```
Then run the examples with `ts-node`, for example `npx ts-node vectorIndex.ts`
## Using the local build
```bash
pnpm install
pnpm --filter llamaindex build
pnpm link ../packages/core
```
Then run the examples with `ts-node`, for example `pnpx ts-node vectorIndex.ts`
+1 -3
View File
@@ -1,6 +1,4 @@
import { stdin as input, stdout as output } from "node:process";
// readline/promises is still experimental so not in @types/node yet
// @ts-ignore
import readline from "node:readline/promises";
import {
@@ -10,7 +8,7 @@ import {
VectorStoreIndex,
} from "llamaindex";
import essay from "./essay.js";
import essay from "./essay";
async function main() {
const document = new Document({ text: essay });
+4 -1
View File
@@ -16,7 +16,10 @@ import {
console.log(nodes);
const keywordExtractor = new KeywordExtractor(openaiLLM, 5);
const keywordExtractor = new KeywordExtractor({
llm: openaiLLM,
keywords: 5,
});
const nodesWithKeywordMetadata = await keywordExtractor.processNodes(nodes);
@@ -19,10 +19,10 @@ import {
}),
]);
const questionsAnsweredExtractor = new QuestionsAnsweredExtractor(
openaiLLM,
5,
);
const questionsAnsweredExtractor = new QuestionsAnsweredExtractor({
llm: openaiLLM,
questions: 5,
});
const nodesWithQuestionsMetadata =
await questionsAnsweredExtractor.processNodes(nodes);
+3 -1
View File
@@ -16,7 +16,9 @@ import {
}),
]);
const summaryExtractor = new SummaryExtractor(openaiLLM);
const summaryExtractor = new SummaryExtractor({
llm: openaiLLM,
});
const nodesWithSummaryMetadata = await summaryExtractor.processNodes(nodes);
+4 -1
View File
@@ -11,7 +11,10 @@ import { Document, OpenAI, SimpleNodeParser, TitleExtractor } from "llamaindex";
}),
]);
const titleExtractor = new TitleExtractor(openaiLLM, 1);
const titleExtractor = new TitleExtractor({
llm: openaiLLM,
nodes: 5,
});
const nodesWithTitledMetadata = await titleExtractor.processNodes(nodes);
-2
View File
@@ -1,6 +1,4 @@
import { stdin as input, stdout as output } from "node:process";
// readline/promises is still experimental so not in @types/node yet
// @ts-ignore
import readline from "node:readline/promises";
import { ChatMessage, LlamaDeuce, OpenAI } from "llamaindex";
+1
View File
@@ -0,0 +1 @@
.ipynb_checkpoints/
+31
View File
@@ -0,0 +1,31 @@
# Jupyter examples
## Preparation
1. Install Deno, e.g. on macOS:
```
brew install deno
```
2. Install Jupyter
```
pip3 install jupyterlab
```
3. Install Deno kernel
```
deno jupyter --unstable --install
```
4. Run Jupyter
```
jupyter lab
```
## Run examples
Then you can open in Jupyter any of the examples in this directory.

Some files were not shown because too many files have changed in this diff Show More