A lightweight toolkit for LLM fine-tuning, inference optimization, and agent development
Project description
geoffrey-llm
A lightweight toolkit for LLM fine-tuning, inference optimization, and agent development.
Features
- geocode - Claude Code-like coding assistant with interactive REPL
- Multi-model support (Kimi, DeepSeek, Qwen, OpenAI-compatible)
- Memory system with file-based storage
- MCP (Model Context Protocol) integration
- Tool calling (File read/write/edit, Bash)
- More features coming soon (LoRA fine-tuning, GraphRAG, etc.)
Installation
pip install geoffrey-llm
Install with all features
pip install geoffrey-llm[all]
Install geocode only
pip install geoffrey-llm[geocode]
Quick Start
Using geocode (REPL)
# After installing geocode
geocode
# Or specify provider
geocode --provider deepseek --model deepseek-chat
Python API
from geoffrey_llm.geocode import REPL
# Create REPL with default settings
repl = REPL()
# Or with specific provider
from geoffrey_llm.geocode.models.base import get_registry, ModelConfig
config = ModelConfig(model_name="moonshot-v1-8k")
registry = get_registry()
model = registry.create("kimi", config)
repl = REPL(model=model)
geocode Module
geocode is a Claude Code-like coding assistant with:
Features
- Interactive REPL - Terminal-based chat interface
- Multi-Model Support - Works with Kimi, DeepSeek, Qwen, and any OpenAI-compatible API
- Memory System - Persistent memory with file-based storage
- MCP Integration - Connect to MCP servers for extended capabilities
- Tool Calling - Built-in tools for file operations and shell commands
Supported Models
| Provider | Model Names | Environment Variable |
|---|---|---|
| Kimi (Moonshot) | moonshot-v1-8k, moonshot-v1-32k, moonshot-v1-128k | KIMI_API_KEY |
| DeepSeek | deepseek-chat, deepseek-coder | DEEPSEEK_API_KEY |
| Qwen (DashScope) | qwen-turbo, qwen-plus, qwen-max | DASHSCOPE_API_KEY |
| OpenAI-compatible | gpt-3.5-turbo, gpt-4, llama3, etc. | OPENAI_API_KEY |
Configuration
Create ~/.geoffrey/config.yaml:
model:
provider: kimi
model_name: moonshot-v1-8k
api_key: ${KIMI_API_KEY} # Or set env var directly
Commands in REPL
| Command | Description |
|---|---|
exit, quit |
End session |
/new |
Start new session |
/resume <id> |
Resume existing session |
/sessions |
List all sessions |
/memory save <type> <content> |
Save a memory |
/memory list [type] |
List memories |
/memory recall <query> |
Search memories |
/mcp list |
List MCP servers |
Memory Types
| Type | Description |
|---|---|
user |
User preferences, identity |
feedback |
User corrections, feedback |
project |
Project-specific context |
reference |
External reference material |
MCP Servers
Configure MCP servers in ~/.geoffrey/mcp.json:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"],
"env": {}
}
}
}
Tool Calling
geocode supports tool calling with built-in tools:
- FileRead - Read files with line offset/limit
- FileWrite - Write content to files
- FileEdit - Edit files using search/replace
- Bash - Execute shell commands (sandboxed)
Memory System
Memories are stored as markdown files with YAML frontmatter in ~/.geoffrey/memory/:
---
id: mem_abc123
type: user
created_at: 2026-04-18T10:00:00Z
updated_at: 2026-04-18T10:00:00Z
tags:
- preference
---
User prefers dark mode interface.
Session Management
Sessions are stored as JSON files in ~/.geoffrey/sessions/. Each session contains:
- Conversation history
- Project context
- Model/ provider settings
- Last active timestamp
License
MIT License
Roadmap
- LoRA/QLoRA fine-tuning interface
- Unified inference backend (vLLM, llama.cpp, TensorRT)
- GraphRAG-lite for knowledge graph RAG
- Log analysis Agent toolkit
- Model quantization utilities (AWQ, GPTQ)
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file geoffrey_llm-0.1.0.tar.gz.
File metadata
- Download URL: geoffrey_llm-0.1.0.tar.gz
- Upload date:
- Size: 33.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
38f6b4a85e2215a5428d7edfc374f77e55697ddb9aeb519c4088f933493ed04b
|
|
| MD5 |
f66d5a4407dd880a52e4ae515541e63b
|
|
| BLAKE2b-256 |
3851f7fa7f0d476bf2284bfcf90624e6ae1a91cb447c7a4f462859c345948eea
|
File details
Details for the file geoffrey_llm-0.1.0-py3-none-any.whl.
File metadata
- Download URL: geoffrey_llm-0.1.0-py3-none-any.whl
- Upload date:
- Size: 43.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
100c2b799ac7299866dbc67a18cf1453ea6e48647763d6d8e59197902b18cd9b
|
|
| MD5 |
10e13729a3f2ab0c28c9200800321ac4
|
|
| BLAKE2b-256 |
0bdd2658f3ac3b2cbd39712554c0784a3792281b50202cf921e01a5338c556aa
|