Skip to main content

Cognitive processing system for HEAVEN - Handles knowledge synthesis across any corpus size

Project description

Brain Agent

Neural-inspired knowledge retrieval system built on heaven-base.

Overview

Brain Agent provides a sophisticated system for organizing and querying knowledge from document collections. It uses a "neural" metaphor where documents become "neurons" that can be activated based on relevance to queries.

Components

  • BrainAgent: Main agent class for knowledge retrieval
  • CognizeTool: Identifies relevant neurons for a query
  • InstructTool: Generates instructions from activated neurons
  • QueryBrainTool: Simple interface for querying registered brains
  • SynthesizerReplicant: Alternative replicant-based interface

Installation

# Install heaven-base first
pip install git+https://github.com/sancovp/heaven-base.git@v1.2.0

# Install brain-agent
pip install -e .

Usage

from brain_agent import BrainAgent, register_brain

# Register a brain (document collection)
register_brain(
    directory="/path/to/documents",
    brain_name="my_knowledge_base",
    chunk_size=-1  # whole files
)

# Create and query brain agent
agent = BrainAgent()
result = await agent.query("brain=my_knowledge_base query=What is machine learning?")

Dependencies

  • heaven-base>=1.2.0 (for core agent framework)
  • langchain-core (for message types)
  • Various LLM providers (OpenAI, Google, etc.)

License

Private - All rights reserved.

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

brain_agent-0.1.4.tar.gz (28.2 kB view details)

Uploaded Source

Built Distribution

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

brain_agent-0.1.4-py3-none-any.whl (20.8 kB view details)

Uploaded Python 3

File details

Details for the file brain_agent-0.1.4.tar.gz.

File metadata

  • Download URL: brain_agent-0.1.4.tar.gz
  • Upload date:
  • Size: 28.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for brain_agent-0.1.4.tar.gz
Algorithm Hash digest
SHA256 94d57b91fe0fc49a74bc2916633988799bf3a53e481fe843a8788b01a2716da8
MD5 813c7c08ba80eb6a0af9c082bfbd9207
BLAKE2b-256 611cce2d38ad7a1913f7cf9a909d5374c1832361d65b805de855ceda2c9c052a

See more details on using hashes here.

File details

Details for the file brain_agent-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: brain_agent-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 20.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for brain_agent-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 9103a956a63866805819cdd7ff967f717edbd93e3f6d02cb27b80e15ae0370c1
MD5 392d69e60e34c3df22099d708555c352
BLAKE2b-256 157e3823558e7ec0706fd6b846ebd756defb3ebd888e2dfcd02613dd29bce2e5

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