langchainjs
instructor
langchainjs | instructor | |
---|---|---|
20 | 27 | |
15,525 | 11,295 | |
1.8% | 1.8% | |
9.9 | 9.6 | |
3 days ago | 4 days ago | |
TypeScript | Python | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
langchainjs
-
`wrapOpenAIClientError` function in libs/langchain-openai sourceĀ code.
You will find the below code in langchainjs/src/utils/openai.ts
-
iife() function in libs/langchain-openai sourceĀ code.
At line 11 in langchain-openai/src/utils/headers.ts
-
deno.json file in langchainjs sourceĀ code.
In this article, we will review deno.json file in lanchainjs source code. we will look at:
-
LangGraph vs LlamaIndex Showdown: Who Makes AI Agents Easier in JavaScript?
LangChain.js on GitHub
-
Top 8 Most Popular Open-Source Next.js Boilerplates/Starter
AI: Langchainjs
- ćTypeScriptćDisplaying ChatGPT-like Streaming Responses with trpc in React
-
Getting started with Valkey using JavaScript
The current implementation uses the node-redis client, but I wanted to try out iovalkey client. I am not a JS/TS expert, but it was simple enough to port the existing implementation.You can refer to the code on GitHub
-
Learning the Basics of Large Language Model (LLM) Applications with LangChainJS
import { GithubRepoLoader } from "langchain/document_loaders/web/github"; import ignore from "ignore"; const loader = new GithubRepoLoader( "https://github.com/langchain-ai/langchainjs", { recursive: false, ignorePaths: ["*.md", "yarn.lock"] } ); const docs = await loader.load(); console.log(docs.slice(0, 3));
-
On the unpredictable nature of LLM output and type safety in LangChain TS
*** all code examples are using LangChain TS on the main branch on September 22nd, 2023 (roughly version 0.0.153).
-
Moving from Typescript and Langchain to Rust and Loops
At the time of the prototype's development, the Langchain GitHub loader sent one request per file to fetch the repository sequentially, leading to prolonged download times. In our case about 2 minutes for the insights.opensauced.pizza repository. This issue was later resolved in hwchase17/langchainjs#2224, enabling parallel requests for faster retrieval.
instructor
- Instructor ā Structured Outputs for LLMs
-
Generative AI: A Personal Deep Dive ā My Notes and Insights Part-2
For those looking for an even easier way to manage structured outputs, the Instructor library is a fantastic tool. Instructor is built on top of Pydantic and aims to simplify the process of getting structured data like JSON from LLMs.
-
Exploring the Instructor Library: Structuring Unstructured Data (and Some Fun along the Way)
Iāve recently come across the instructor library, and I have to say, Iām pretty impressed. The concept of structuring unstructured data is both powerful and, dare I say, a bit magical. The idea that you can take data thatās all over the place and somehow impose order on itāwell, thatās just my kind of wizardry.
-
Tactics for multi-step LLM app experimentation
We will start with generating some synthetic data for our app. For that we will use Viratās processed AirBnB 2023 10k filings dataset and generate synthetic data for the sub-step (expanding the keyword into a query). As this dataset contains triplets of question, context and answer, we will do the inverse of the sub-step: generate a keyword query from the provided question. To do that, we will use Instructor with the OpenAI API to generate the keyword query.
-
Every Way to Get Structured Output from LLMs
If you look into the instructor code(https://github.com/jxnl/instructor/blob/06a49e7824729b8df1f7...). Here is the core code snippet they use:
```
- Instructor: Structured Outputs for LLMs
- AIM Weekly 27 May 2024
-
Instructor-Go ā Structured LLM Outputs in Go
instructor-go is a port of the popular Python package https://github.com/jxnl/instructor.
This implementation uses `jsonschema` and Go struct tags to send data and schema information to the model to return the appropriate response schema.
Currently, OpenAI and Anthropic are supported, and you can see all examples of different capabilities here: https://github.com/instructor-ai/instructor-go/tree/main/exa....
This is in early development and would love some feedback.
Thanks for checking it out!
- Show HN: Anthropic's Prompt Engineering Interactive Tutorial (Web Version)
-
Structured: Extract Data from Unstructured Input with LLM
The Structured project started as a Go conversion of Instructor, but it is a more general-purpose library. It is designed to be extremely easy to use and set up.
What are some alternatives?
camel - š« CAMEL: The first and the best multi-agent framework. Finding the Scaling Law of Agents. https://www.camel-ai.org
continuous-eval - Data-Driven Evaluation for LLM-Powered Applications
modelfusion - The TypeScript library for building AI applications.
hyperdx - Resolve production issues, fast. An open source observability platform unifying session replays, logs, metrics, traces and errors powered by Clickhouse and OpenTelemetry.
ort - Fast ML inference & training for ONNX models in Rust
simpleaichat - Python package for easily interfacing with chat apps, with robust features and minimal code complexity.