Codename: Symbiont - Building an evolving AI with a Rust-based microservice stack.
Rust
0
53 commits
updated May 26, 2025
An evolving AI organism pet project.
Creating a "digital organism" (Symbiote) that:
The project is actively under development and has achieved key milestones:
MVP 3: Advanced NLP & Vector Search Integration - COMPLETE (v0.3.0)
This milestone significantly enhances the Symbiont's understanding and retrieval capabilities by:
preprocessing_service): Text is now processed into sentence embeddings using the candle ML framework (with a sentence-transformers model). This allows for understanding semantic similarity.vector_memory_service): A new service stores these embeddings and associated metadata in a Qdrant vector database.api_service now orchestrates a semantic search pipeline, converting user queries into embeddings and querying the vector_memory_service.frontend) features a new section allowing users to perform semantic searches over the ingested and processed data, viewing relevant text snippets, their sources, and similarity scores.MVP 2: Basic Text Generation & UI - COMPLETE (v0.2.0)
This milestone introduces the Symbiont's ability to generate text and interact with users via a web interface. Key capabilities include:
api_service, text_generator_service, frontend) are containerized and orchestrated with Docker Compose.MVP 1: Data Ingestion Pipeline - COMPLETE (v0.1.0)
The first initial milestone of "Codename: Symbiont" is complete. The system can currently:
All components are containerized using Docker and orchestrated with Docker Compose.
tokenizers crate, candle (for ML inference/embeddings)qdrant-client)log + env_logger for Rust services.Running the Symbiont System:
Prerequisites:
curl (for interacting with the API service)nats-cli (optional, for sending NATS messages manually) - installation instructions here.Clone the repository:
git clone https://github.com/makkenzo/codename-symbiont.git
cd codename-symbiont
Environment Configuration:
cp .env.example .env.env and set your desired NEO4J_PASSWORD (default user is neo4j).API_SERVER_PORT (defaults to 8080, for the API service) and FRONTEND_PORT (defaults to 3000, for the Web UI)..env file also defines:
NEXT_PUBLIC_API_URL_FOR_FRONTEND_BUILD (e.g., http://localhost:${API_SERVER_PORT}/api): This URL is embedded into the frontend during its build process to allow it to communicate with the API service.NEXT_PUBLIC_API_URL_FOR_FRONTEND_RUNTIME (e.g., http://cs-api-service:${API_SERVER_INTERNAL_PORT}/api): This URL is used by the running frontend container to communicate with the API service container. Users typically do not need to change this, as it's for internal Docker network communication and relies on API_SERVER_INTERNAL_PORT.Build and run the services:
docker-compose up --build
This will build the Rust services and start all containers (NATS, Neo4j, Qdrant, the Symbiont services, and the frontend service). Wait for all services to initialize. You should see logs indicating they are ready. A web interface will be available.
Interacting with the System:
Once the system is running, you can interact with it in several ways:
Web UI:
The primary way to interact with the Symbiont system is now through its web interface.
It is typically accessible at http://localhost:3000 (or the FRONTEND_PORT you've configured in the .env file).
The Web UI provides the following functionalities:
api_service.Submitting URLs for Processing: (Note: This action can also be performed via the Web UI. The methods below detail API/CLI interactions, suitable for advanced users or scripting.)
This is part of the data ingestion pipeline. You can submit URLs via:
nats-cli:
nats pub tasks.perceive.url '{"url":"https://www.example.com"}'
api_service also exposes an endpoint for this at POST /api/submit-url.Generating Text: (Note: This action, including receiving generated text via SSE, can also be performed via the Web UI. The methods below detail API/CLI interactions, suitable for advanced users or scripting.)
Send a POST request to the api_service to trigger text generation. By default, the api_service listens on port 8080.
Endpoint: POST http://localhost:8080/api/generate-text
Payload Structure (GenerateTextTask):
{
"task_id": "your-unique-task-id", // Should be a UUID
"prompt": "An optional prompt for the text generator", // Optional
"max_length": 50 // Max length of generated text
}
curl Example:
The uuidgen command can be used to generate a unique task ID. If uuidgen is not available on your system, replace $(uuidgen) with any unique string.
curl -X POST -H "Content-Type: application/json" \
-d '{"task_id":"$(uuidgen)","prompt":"Hello world","max_length":30}' \
http://localhost:8080/api/generate-text
The response to this POST request will confirm that the task has been submitted.
Receiving Generated Text via SSE: Generated text segments are streamed back to clients via Server-Sent Events (SSE).
Endpoint: GET http://localhost:8080/api/events
curl Example to connect to the SSE stream:
curl -N http://localhost:8080/api/events
You will see a stream of events. Each event is a JSON object representing a GeneratedTextMessage:
data: {"original_task_id":"your-unique-task-id","generated_text":"Generated sample text...","timestamp_ms":1678886400000}
(Expect multiple such data: lines as text is generated.)
Track my progress and upcoming features on Trello.
candle for ML model inference (sentence embeddings).vector_memory_service).candle (e.g., smaller GPT-2 or other generative models).The project continues to evolve. Recent developments include the introduction of text generation capabilities (see 'Project Status' above). Future work will focus on enhancing these generative models and further expanding the Symbiont's understanding of ingested data.
This project is licensed under either of
Apache License, Version 2.0, (LICENSE-APACHE)
MIT license (LICENSE-MIT)
at your option.
53 commits
Rust
77.1%
TypeScript
14.0%
Dockerfile
8.1%
Codename: Symbiont - Building an evolving AI with a Rust-based microservice stack.
Rust
0
53 commits
updated May 26, 2025
An evolving AI organism pet project.
Creating a "digital organism" (Symbiote) that:
The project is actively under development and has achieved key milestones:
MVP 3: Advanced NLP & Vector Search Integration - COMPLETE (v0.3.0)
This milestone significantly enhances the Symbiont's understanding and retrieval capabilities by:
preprocessing_service): Text is now processed into sentence embeddings using the candle ML framework (with a sentence-transformers model). This allows for understanding semantic similarity.vector_memory_service): A new service stores these embeddings and associated metadata in a Qdrant vector database.api_service now orchestrates a semantic search pipeline, converting user queries into embeddings and querying the vector_memory_service.frontend) features a new section allowing users to perform semantic searches over the ingested and processed data, viewing relevant text snippets, their sources, and similarity scores.MVP 2: Basic Text Generation & UI - COMPLETE (v0.2.0)
This milestone introduces the Symbiont's ability to generate text and interact with users via a web interface. Key capabilities include:
api_service, text_generator_service, frontend) are containerized and orchestrated with Docker Compose.MVP 1: Data Ingestion Pipeline - COMPLETE (v0.1.0)
The first initial milestone of "Codename: Symbiont" is complete. The system can currently:
All components are containerized using Docker and orchestrated with Docker Compose.
tokenizers crate, candle (for ML inference/embeddings)qdrant-client)log + env_logger for Rust services.Running the Symbiont System:
Prerequisites:
curl (for interacting with the API service)nats-cli (optional, for sending NATS messages manually) - installation instructions here.Clone the repository:
git clone https://github.com/makkenzo/codename-symbiont.git
cd codename-symbiont
Environment Configuration:
cp .env.example .env.env and set your desired NEO4J_PASSWORD (default user is neo4j).API_SERVER_PORT (defaults to 8080, for the API service) and FRONTEND_PORT (defaults to 3000, for the Web UI)..env file also defines:
NEXT_PUBLIC_API_URL_FOR_FRONTEND_BUILD (e.g., http://localhost:${API_SERVER_PORT}/api): This URL is embedded into the frontend during its build process to allow it to communicate with the API service.NEXT_PUBLIC_API_URL_FOR_FRONTEND_RUNTIME (e.g., http://cs-api-service:${API_SERVER_INTERNAL_PORT}/api): This URL is used by the running frontend container to communicate with the API service container. Users typically do not need to change this, as it's for internal Docker network communication and relies on API_SERVER_INTERNAL_PORT.Build and run the services:
docker-compose up --build
This will build the Rust services and start all containers (NATS, Neo4j, Qdrant, the Symbiont services, and the frontend service). Wait for all services to initialize. You should see logs indicating they are ready. A web interface will be available.
Interacting with the System:
Once the system is running, you can interact with it in several ways:
Web UI:
The primary way to interact with the Symbiont system is now through its web interface.
It is typically accessible at http://localhost:3000 (or the FRONTEND_PORT you've configured in the .env file).
The Web UI provides the following functionalities:
api_service.Submitting URLs for Processing: (Note: This action can also be performed via the Web UI. The methods below detail API/CLI interactions, suitable for advanced users or scripting.)
This is part of the data ingestion pipeline. You can submit URLs via:
nats-cli:
nats pub tasks.perceive.url '{"url":"https://www.example.com"}'
api_service also exposes an endpoint for this at POST /api/submit-url.Generating Text: (Note: This action, including receiving generated text via SSE, can also be performed via the Web UI. The methods below detail API/CLI interactions, suitable for advanced users or scripting.)
Send a POST request to the api_service to trigger text generation. By default, the api_service listens on port 8080.
Endpoint: POST http://localhost:8080/api/generate-text
Payload Structure (GenerateTextTask):
{
"task_id": "your-unique-task-id", // Should be a UUID
"prompt": "An optional prompt for the text generator", // Optional
"max_length": 50 // Max length of generated text
}
curl Example:
The uuidgen command can be used to generate a unique task ID. If uuidgen is not available on your system, replace $(uuidgen) with any unique string.
curl -X POST -H "Content-Type: application/json" \
-d '{"task_id":"$(uuidgen)","prompt":"Hello world","max_length":30}' \
http://localhost:8080/api/generate-text
The response to this POST request will confirm that the task has been submitted.
Receiving Generated Text via SSE: Generated text segments are streamed back to clients via Server-Sent Events (SSE).
Endpoint: GET http://localhost:8080/api/events
curl Example to connect to the SSE stream:
curl -N http://localhost:8080/api/events
You will see a stream of events. Each event is a JSON object representing a GeneratedTextMessage:
data: {"original_task_id":"your-unique-task-id","generated_text":"Generated sample text...","timestamp_ms":1678886400000}
(Expect multiple such data: lines as text is generated.)
Track my progress and upcoming features on Trello.
candle for ML model inference (sentence embeddings).vector_memory_service).candle (e.g., smaller GPT-2 or other generative models).The project continues to evolve. Recent developments include the introduction of text generation capabilities (see 'Project Status' above). Future work will focus on enhancing these generative models and further expanding the Symbiont's understanding of ingested data.
This project is licensed under either of
Apache License, Version 2.0, (LICENSE-APACHE)
MIT license (LICENSE-MIT)
at your option.
53 commits
Rust
77.1%
TypeScript
14.0%
Dockerfile
8.1%