Skip to main content

LLM plugin for iaedu-adapter

Project description

llm-iaedu

A plugin for LLM that enables using the iaedu-adapter as a model.

Installation

# Install LLM if you don't have it
pip install llm

# Install this plugin
pip install llm-iaedu

Or for development:

git clone https://github.com/yourname/llm-iaedu.git
cd llm-iaedu
pip install -e .

Setup

  1. Get your IAEDU API key from iaedu.pt

  2. Set the API key using LLM's key management:

    llm keys set iaedu
    # Paste your API key when prompted
    
  3. Ensure the iaedu-adapter is running:

    # In another terminal
    npm install  # if you haven't already
    npm start    # or however you run the adapter
    # The adapter should be accessible at http://localhost:4000
    

Usage

Once installed and configured, you can use the iaedu model like any other LLM model:

llm -m iaedu "What is the capital of Portugal?"

You can also use it in chat mode:

llm chat -m iaedu

Configuration

The plugin uses the following environment variable:

  • IAEDU_ENDPOINT: URL of the iaedu-adapter (default: http://localhost:4000)

Example:

IAEDU_ENDPOINT=http://my-server:8000 llm -m iaedu "Hello"

How it works

This plugin acts as a bridge between LLM and the iaedu-adapter:

  1. LLM calls the plugin with a prompt
  2. The plugin retrieves your IAEDU API key using LLM's key management system
  3. The plugin forwards the request to your iaedu-adapter instance
  4. The adapter communicates with the iaedu.pt API
  5. The plugin streams the response back to LLM

Requirements

  • LLM installed
  • iaedu-adapter running and accessible
  • Valid IAEDU API key

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

llm_iaedu-0.1.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

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

llm_iaedu-0.1-py3-none-any.whl (7.6 kB view details)

Uploaded Python 3

File details

Details for the file llm_iaedu-0.1.tar.gz.

File metadata

  • Download URL: llm_iaedu-0.1.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for llm_iaedu-0.1.tar.gz
Algorithm Hash digest
SHA256 b9da90c8b48fe107b0b0c4eec39373303fd5c90ba9d120e42d7f12fdf7874876
MD5 61faf67b8386138e1423bdc8fecbdf73
BLAKE2b-256 a57c4173b64a3b493acf6bfc47905ff681dc3a2a1aaf588c3137313c0c3170d5

See more details on using hashes here.

File details

Details for the file llm_iaedu-0.1-py3-none-any.whl.

File metadata

  • Download URL: llm_iaedu-0.1-py3-none-any.whl
  • Upload date:
  • Size: 7.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for llm_iaedu-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8a5568b4c998e7a6f003a27e57f0e36bf70af3dfad09246256d08b0b929ee638
MD5 c2e68e712a2417120d687e04ee2b6378
BLAKE2b-256 25d3bf887710f4280f8a11880e2fdef719c4b85bb723a4327bc312e8252ba202

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