Skip to main content

Extract information with LLMs from text

Project description

⚠ WARNING: Prototype with unstable API. 🚧

Kor

This is a half-baked prototype that "helps" you extract structured data from text using LLMs 🧩.

Specify the schema of what should be extracted and provide some examples.

Kor will generate a prompt, send it to the specified LLM and parse out the output. You might even get results back.

See documentation.

💡 Ideas

Ideas of some things that could be done with Kor.

  • Extract data from text: Define what information should be extracted from a segment
  • Convert an HTML form into a Kor form and allow the user to fill it out using natural language. (Convert HTML forms -> API? Or not.)
  • Add some skills to an AI assistant

🚧 Prototype

This a prototype and the API is not expected to be stable as it hasn't been tested against real world examples.

✨ does Kor excel at? 🌟

  • Making mistakes! Plenty of them. Quality varies with the underlying language model, the quality of the prompt, and the number of bugs in the adapter code.
  • Slow! It uses large prompts with examples, and works best with the larger slower LLMs.
  • Crashing for long enough pieces of text! Context length window could become limiting when working with large forms or long text inputs.
  • Incorrectly grouping results (see documentation section on objects).

Potential Changes

  • Adding validators
  • Built-in components to quickly assemble schema with examples
  • Add routing layer to select appropriate extraction schema for a use case when many schema exist

🎶 Why the name?

Fast to type and sufficiently unique.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kor-0.2.0.tar.gz (12.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kor-0.2.0-py3-none-any.whl (14.8 kB view details)

Uploaded Python 3

File details

Details for the file kor-0.2.0.tar.gz.

File metadata

  • Download URL: kor-0.2.0.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.2 CPython/3.10.8 Linux/6.0.2-76060002-generic

File hashes

Hashes for kor-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c6f7226a0e87ab353abd599902029bb115ade46dc4a910d59ab1bde5e192be56
MD5 1554fc2a61e366658aeddfec0f759be7
BLAKE2b-256 630f89e104e6365b4337a383cea5ac03888527b691d0bd2a9a2620a5d531f032

See more details on using hashes here.

File details

Details for the file kor-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: kor-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 14.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.2 CPython/3.10.8 Linux/6.0.2-76060002-generic

File hashes

Hashes for kor-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 45c7aafd2ac21809573b76dbe66066f6ce76af2897e1efaa1d61b87e8a6bdf68
MD5 7b867cfe9db093771b65ece251c0a849
BLAKE2b-256 60f7e68bb4dac988d75a86d1a99a83693182f85723697a6a9b0ea90528aa8062

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page