From a09b75f27c186e7a5a054d87b3deb1ff3d706f1e Mon Sep 17 00:00:00 2001 From: Subhajit Das Date: Mon, 23 Mar 2026 16:44:09 +0530 Subject: [PATCH 1/2] feat(examples): add collaborative agents demo showing Internet of Agents Three bindufied agents demonstrating A2A protocol communication: - research_agent: searches web using DuckDuckGo (port 3773) - memory_agent: stores/retrieves knowledge via semantic similarity (port 3774) - coordinator_agent: orchestrates research + memory agents (port 3775) Each agent has its own DID identity. Coordinator calls research and memory agents over HTTP using the A2A protocol. Verified working end-to-end: coordinator retrieves from memory on repeat queries, falls back to research agent on cache miss, stores new knowledge. Part of the Internet of Agents vision. --- examples/collaborative-agents/.gitignore | 3 + examples/collaborative-agents/README.md | 228 ++++++++++++++++++ .../collaborative-agents/coordinator_agent.py | 117 +++++++++ examples/collaborative-agents/memory_agent.py | 46 ++++ .../collaborative-agents/requirements.txt | 7 + .../collaborative-agents/research_agent.py | 52 ++++ .../utils/semantic_memory.py | 71 ++++++ 7 files changed, 524 insertions(+) create mode 100644 examples/collaborative-agents/.gitignore create mode 100644 examples/collaborative-agents/README.md create mode 100644 examples/collaborative-agents/coordinator_agent.py create mode 100644 examples/collaborative-agents/memory_agent.py create mode 100644 examples/collaborative-agents/requirements.txt create mode 100644 examples/collaborative-agents/research_agent.py create mode 100644 examples/collaborative-agents/utils/semantic_memory.py diff --git a/examples/collaborative-agents/.gitignore b/examples/collaborative-agents/.gitignore new file mode 100644 index 00000000..9204635c --- /dev/null +++ b/examples/collaborative-agents/.gitignore @@ -0,0 +1,3 @@ +.env +__pycache__/ +*.pyc \ No newline at end of file diff --git a/examples/collaborative-agents/README.md b/examples/collaborative-agents/README.md new file mode 100644 index 00000000..7ecf99d6 --- /dev/null +++ b/examples/collaborative-agents/README.md @@ -0,0 +1,228 @@ +# ๐ŸŒ Bindu Collaborative Agents +### A Multi-Agent AI System with Semantic Memory using the Bindu Ecosystem + +This project demonstrates a **collaborative AI agent system** inspired by the **Bindu Framework** and the concept of the **Internet of Agents**. + +The system contains multiple agents that **communicate, collaborate, and learn over time using semantic memory**. + +--- + +# ๐Ÿš€ Features + +โœ… Multi-Agent Collaboration +โœ… Semantic Vector Memory +โœ… Agent Orchestration +โœ… Knowledge Retrieval with Embeddings +โœ… Dynamic Learning System + +The system demonstrates how **agents can research, store knowledge, and recall it later**. + +--- + +# ๐Ÿง  System Architecture +```text +User Query + โ†“ +Coordinator Agent + โ†“ +Memory Agent (Semantic Search) + โ†“ +If Found โ†’ Return Memory +If Not Found โ†’ Research Agent + โ†“ +Store Knowledge + โ†“ +Return Response +``` + + +This architecture demonstrates **agent collaboration and knowledge persistence**. + +--- + +# ๐Ÿค– Agents in the System + +### 1๏ธโƒฃ Coordinator Agent +Acts as the **central orchestrator**. + +Responsibilities: + +- Receives user queries +- Checks semantic memory +- Delegates research tasks +- Stores new knowledge + +--- + +### 2๏ธโƒฃ Research Agent +Responsible for **generating knowledge**. + +Capabilities: + +- Uses LLM reasoning +- Generates explanations +- Provides structured information + +--- + +### 3๏ธโƒฃ Memory Agent +Handles **semantic knowledge storage**. + +Capabilities: + +- Generates embeddings +- Stores vector memory +- Retrieves relevant knowledge using cosine similarity + +--- + +# ๐Ÿ“ฆ Project Structure +```bash +bindu-collaborative-agents +โ”‚ +โ”œโ”€โ”€ coordinator_agent.py +โ”œโ”€โ”€ research_agent.py +โ”œโ”€โ”€ memory_agent.py +โ”œโ”€โ”€ run_system.py +โ”‚ +โ”œโ”€โ”€ utils +โ”‚ โ””โ”€โ”€ semantic_memory.py +โ”‚ +โ””โ”€โ”€ requirements.txt +``` + +# โš™๏ธ Installation + +### 1๏ธโƒฃ Clone the repository +git clone https://github.com/Subhajitdas99/bindu-collaborative-agents.git + +cd bindu-collaborative-agents + + +--- + +### 2๏ธโƒฃ Install dependencies +pip install -r requirements.txt + + +--- + +### 3๏ธโƒฃ Set API Key + +This project uses **OpenRouter for LLM access**. +export OPENROUTER_API_KEY="your-api-key" + +Windows PowerShell: +$env:OPENROUTER_API_KEY="your-api-key" + + +--- + +# โ–ถ๏ธ Run the System +python run_system.py + + +Example: +User > What is the Bindu Framework? + +Coordinator thinking... + +๐Ÿ“š Stored memory: The Bindu Framework is a platform for interoperable AI agents... + +Agent > The Bindu Framework enables agents to communicate within the Internet of Agents. + + +--- + +# ๐Ÿงช Example Interaction + + +User > What is the Bindu Framework? + +Coordinator thinking... +๐Ÿ“š Stored memory... + +Agent > Explanation about Bindu. + +User > What is Bindu again? + +Coordinator thinking... +๐Ÿง  Retrieved knowledge from memory. + +Agent > (From Memory) The Bindu Framework... + + +This demonstrates **semantic memory retrieval**. + +--- + +# ๐ŸŒ Internet of Agents + +Bindu promotes a future where AI agents: + +- communicate with each other +- collaborate across systems +- exchange value +- operate autonomously + +This project demonstrates a **simple prototype of that vision**. + +--- + +# ๐Ÿ”ง Technologies Used + +- Python +- OpenRouter API +- OpenAI Embeddings +- NumPy +- Vector Similarity Search + +--- + +# ๐ŸŽฏ Use Cases + +This architecture can be extended to build: + +- Autonomous research agents +- Collaborative AI assistants +- Knowledge-learning AI systems +- Multi-agent decision systems + +--- + +# ๐Ÿ† Bindu AI Agent Challenge + +This project was created for the **Bindu AI Agent Competition** celebrating **International Women's Day**. + +Goal: + +Build an AI agent system demonstrating the **Internet of Agents**. + +--- + +# ๐Ÿ“š Resources + +Bindu Documentation +https://docs.getbindu.com + +Bindu GitHub +https://github.com/GetBindu/Bindu + +--- + +# ๐Ÿ‘จโ€๐Ÿ’ป Author + +**Subhajit Das** +Final Year B.Tech AI/ML Student +Interested in Multi-Agent Systems, AI Infrastructure, and Autonomous Agents. + +--- + +# โญ Support + +If you found this project interesting: + +โญ Star the repository +๐Ÿš€ Share with the AI community + +Let's build the **Internet of Agents** together. \ No newline at end of file diff --git a/examples/collaborative-agents/coordinator_agent.py b/examples/collaborative-agents/coordinator_agent.py new file mode 100644 index 00000000..c5bfd1e7 --- /dev/null +++ b/examples/collaborative-agents/coordinator_agent.py @@ -0,0 +1,117 @@ +"""Coordinator agent โ€” orchestrates research and memory agents.""" +from dotenv import load_dotenv +load_dotenv() +import os +import time + +import httpx +from bindu.penguin.bindufy import bindufy + +MEMORY_AGENT_URL = os.getenv("MEMORY_AGENT_URL", "http://localhost:3774") +RESEARCH_AGENT_URL = os.getenv("RESEARCH_AGENT_URL", "http://localhost:3773") + +import uuid + + +def call_agent(url: str, message: str) -> str: + """Send a message to another Bindu agent, poll until complete, return result.""" + msg_id = str(uuid.uuid4()) + ctx_id = str(uuid.uuid4()) + task_id = str(uuid.uuid4()) + rpc_id = str(uuid.uuid4()) + + payload = { + "jsonrpc": "2.0", + "method": "message/send", + "params": { + "message": { + "role": "user", + "parts": [{"kind": "text", "text": message}], + "kind": "message", + "messageId": msg_id, + "contextId": ctx_id, + "taskId": task_id, + }, + "configuration": {"acceptedOutputModes": ["application/json"]}, + }, + "id": rpc_id, + } + + # Send the message + response = httpx.post(url, json=payload, timeout=30) + result = response.json() + actual_task_id = result.get("result", {}).get("id") + if not actual_task_id: + return "No response from agent" + + # Poll until completed + for _ in range(30): + time.sleep(1) + poll_payload = { + "jsonrpc": "2.0", + "method": "tasks/get", + "params": {"taskId": actual_task_id}, + "id": str(uuid.uuid4()), + } + poll_response = httpx.post(url, json=poll_payload, timeout=10) + poll_result = poll_response.json().get("result", {}) + state = poll_result.get("status", {}).get("state") + + if state == "completed": + artifacts = poll_result.get("artifacts", []) + if artifacts: + parts = artifacts[0].get("parts", []) + if parts: + text = parts[0].get("text", "") + # Don't return error responses + if text and "No response from agent" not in text: + return text + return "No response from agent" + + return "Agent timed out" + + +def handler(messages: list[dict]) -> str: + """Coordinate memory and research agents to answer a query.""" + query = messages[-1]["content"] + + # 1. Try memory first + memory_result = call_agent(MEMORY_AGENT_URL, f"retrieve:{query}") + if memory_result and memory_result not in ( + "No relevant memory found.", + "No response from agent", + "Agent timed out", + ): + print("Retrieved from memory.") + return f"(From Memory) {memory_result}" + + # 2. Fall back to research + print("Researching...") + research_result = call_agent(RESEARCH_AGENT_URL, query) + + # 3. Store only valid results + if research_result and research_result not in ( + "No response from agent", + "Agent timed out", + ): + call_agent(MEMORY_AGENT_URL, f"store:{research_result}") + + return research_result + + +config = { + "author": os.getenv("BINDU_AUTHOR", "your.email@example.com"), + "name": "coordinator_agent", + "description": ( + "Coordinates research and memory agents to answer questions " + "about the Bindu framework." + ), + "deployment": { + "url": os.getenv("BINDU_DEPLOYMENT_URL", "http://localhost:3775"), + "expose": True, + }, + "skills": [], +} + +if __name__ == "__main__": + bindufy(config, handler) \ No newline at end of file diff --git a/examples/collaborative-agents/memory_agent.py b/examples/collaborative-agents/memory_agent.py new file mode 100644 index 00000000..24955019 --- /dev/null +++ b/examples/collaborative-agents/memory_agent.py @@ -0,0 +1,46 @@ +"""Memory agent โ€” stores and retrieves knowledge using semantic similarity.""" +from dotenv import load_dotenv +load_dotenv() +import os + +from bindu.penguin.bindufy import bindufy +from utils.semantic_memory import retrieve_memory, store_memory + + +def handler(messages: list[dict]) -> str: + """Handle store or retrieve memory requests. + + Message format: + store: โ€” stores text in memory + retrieve: โ€” retrieves similar memories + """ + content = messages[-1]["content"] + + if content.startswith("store:"): + text = content[len("store:"):].strip() + store_memory(text) + return f"Stored in memory: {text[:80]}..." + + elif content.startswith("retrieve:"): + query = content[len("retrieve:"):].strip() + results = retrieve_memory(query) + if results: + return results[0]["text"] + return "No relevant memory found." + + return "Unknown command. Use store: or retrieve:." + + +config = { + "author": os.getenv("BINDU_AUTHOR", "your.email@example.com"), + "name": "memory_agent", + "description": "Stores and retrieves knowledge using semantic similarity.", + "deployment": { + "url": os.getenv("BINDU_DEPLOYMENT_URL", "http://localhost:3774"), + "expose": True, + }, + "skills": [], +} + +if __name__ == "__main__": + bindufy(config, handler) \ No newline at end of file diff --git a/examples/collaborative-agents/requirements.txt b/examples/collaborative-agents/requirements.txt new file mode 100644 index 00000000..b72fdccf --- /dev/null +++ b/examples/collaborative-agents/requirements.txt @@ -0,0 +1,7 @@ +bindu +agno +openai +numpy +httpx +python-dotenv + diff --git a/examples/collaborative-agents/research_agent.py b/examples/collaborative-agents/research_agent.py new file mode 100644 index 00000000..822b50c3 --- /dev/null +++ b/examples/collaborative-agents/research_agent.py @@ -0,0 +1,52 @@ +"""Research agent โ€” searches the web and answers questions about Bindu.""" +from dotenv import load_dotenv +load_dotenv() +import os + +from agno.agent import Agent +from agno.models.openai import OpenAIChat +from agno.tools.duckduckgo import DuckDuckGoTools +from bindu.penguin.bindufy import bindufy + +model = OpenAIChat( + id="openai/gpt-4o-mini", + base_url="https://openrouter.ai/api/v1", + api_key=os.getenv("OPENROUTER_API_KEY"), +) + +research_agent = Agent( + instructions=""" +You are a research agent specialized in the Bindu AI Framework. +If the user asks about Bindu, assume they mean the Bindu AI framework +used for building interoperable AI agents. +Search and explain concepts like: +- Internet of Agents +- Bindu Framework +- Agent-to-Agent communication +- Bindu architecture +""", + model=model, + tools=[DuckDuckGoTools()], +) + + +def handler(messages: list[dict]) -> str: + """Handle incoming messages and return research results.""" + query = messages[-1]["content"] + result = research_agent.run(input=query) + return result.content + + +config = { + "author": os.getenv("BINDU_AUTHOR", "your.email@example.com"), + "name": "research_agent", + "description": "Searches the web and answers questions using DuckDuckGo.", + "deployment": { + "url": os.getenv("BINDU_DEPLOYMENT_URL", "http://localhost:3773"), + "expose": True, + }, + "skills": [], +} + +if __name__ == "__main__": + bindufy(config, handler) \ No newline at end of file diff --git a/examples/collaborative-agents/utils/semantic_memory.py b/examples/collaborative-agents/utils/semantic_memory.py new file mode 100644 index 00000000..da1a4bd7 --- /dev/null +++ b/examples/collaborative-agents/utils/semantic_memory.py @@ -0,0 +1,71 @@ +import numpy as np +import os +from openai import OpenAI + +# Configure OpenRouter client +client = OpenAI( + api_key=os.getenv("OPENROUTER_API_KEY"), + base_url="https://openrouter.ai/api/v1" +) + +memory_store = [] + + +def get_embedding(text: str): + response = client.embeddings.create( + model="text-embedding-3-small", + input=text + ) + return response.data[0].embedding + + +def cosine_similarity(v1, v2): + v1 = np.array(v1) + v2 = np.array(v2) + return np.dot(v1, v2) / (np.linalg.norm(v1) * np.linalg.norm(v2)) + + +def store_memory(text: str): + embedding = get_embedding(text) + + memory_store.append({ + "text": text, + "embedding": embedding + }) + + print(f"๐Ÿ“š Stored memory: {text[:80]}...") + + +def retrieve_memory(query: str, top_k: int = 1): + + if not memory_store: + return [] + + query_embedding = get_embedding(query) + + scores = [] + + for item in memory_store: + similarity = cosine_similarity(query_embedding, item["embedding"]) + + scores.append({ + "text": item["text"], + "score": similarity + }) + + scores = sorted(scores, key=lambda x: x["score"], reverse=True) + + # Only return if similarity is strong + SIMILARITY_THRESHOLD = 0.75 + results = [s for s in scores if s["score"] >= SIMILARITY_THRESHOLD] + + # Prefer most recent stored memory + results = sorted( + results, + key=lambda x: memory_store.index( + next(item for item in memory_store if item["text"] == x["text"]) + ), + reverse=True + ) + + return results[:top_k] From 9097a6aa1403038446d0e945a0fbfdf4b3d2edb1 Mon Sep 17 00:00:00 2001 From: Subhajit Das Date: Mon, 23 Mar 2026 16:51:08 +0530 Subject: [PATCH 2/2] docs: update collaborative agents README with full setup and testing guide --- examples/collaborative-agents/README.md | 323 +++++++++++++----------- 1 file changed, 169 insertions(+), 154 deletions(-) diff --git a/examples/collaborative-agents/README.md b/examples/collaborative-agents/README.md index 7ecf99d6..0aa20ac9 100644 --- a/examples/collaborative-agents/README.md +++ b/examples/collaborative-agents/README.md @@ -1,228 +1,243 @@ -# ๐ŸŒ Bindu Collaborative Agents -### A Multi-Agent AI System with Semantic Memory using the Bindu Ecosystem +# Bindu Collaborative Agents -This project demonstrates a **collaborative AI agent system** inspired by the **Bindu Framework** and the concept of the **Internet of Agents**. +A working multi-agent system demonstrating the **Internet of Agents** using the Bindu framework. -The system contains multiple agents that **communicate, collaborate, and learn over time using semantic memory**. +Three specialized agents collaborate to answer questions โ€” each with its own DID identity, +communicating over the A2A protocol. --- -# ๐Ÿš€ Features +## System Architecture -โœ… Multi-Agent Collaboration -โœ… Semantic Vector Memory -โœ… Agent Orchestration -โœ… Knowledge Retrieval with Embeddings -โœ… Dynamic Learning System - -The system demonstrates how **agents can research, store knowledge, and recall it later**. - ---- - -# ๐Ÿง  System Architecture -```text +``` User Query โ†“ -Coordinator Agent - โ†“ -Memory Agent (Semantic Search) - โ†“ -If Found โ†’ Return Memory -If Not Found โ†’ Research Agent - โ†“ -Store Knowledge - โ†“ -Return Response +Coordinator Agent (port 3775) + โ†“ โ†“ +Memory Agent Research Agent +(port 3774) (port 3773) + โ†“ โ†“ +Semantic DuckDuckGo +Retrieval Web Search ``` - -This architecture demonstrates **agent collaboration and knowledge persistence**. +**Flow:** +1. User sends query to Coordinator +2. Coordinator checks Memory Agent (semantic similarity search) +3. If found in memory โ†’ return instantly +4. If not found โ†’ Research Agent searches the web +5. Answer stored in Memory Agent for future queries +6. Response returned to user --- -# ๐Ÿค– Agents in the System - -### 1๏ธโƒฃ Coordinator Agent -Acts as the **central orchestrator**. - -Responsibilities: - -- Receives user queries -- Checks semantic memory -- Delegates research tasks -- Stores new knowledge +## Agents ---- +### Research Agent (port 3773) +Searches the web using DuckDuckGo and answers questions using an LLM via OpenRouter. +Specialized in the Bindu AI framework and Internet of Agents concepts. -### 2๏ธโƒฃ Research Agent -Responsible for **generating knowledge**. +### Memory Agent (port 3774) +Stores and retrieves knowledge using vector embeddings and cosine similarity. +Uses `text-embedding-3-small` via OpenRouter. Threshold of 0.75 similarity +ensures only relevant memories are returned. -Capabilities: +Commands: +- `store:` โ€” stores text in semantic memory +- `retrieve:` โ€” retrieves most similar memory -- Uses LLM reasoning -- Generates explanations -- Provides structured information +### Coordinator Agent (port 3775) +Orchestrates the other two agents. Checks memory first, falls back to research, +stores new knowledge automatically. Each call uses the A2A `message/send` protocol. --- -### 3๏ธโƒฃ Memory Agent -Handles **semantic knowledge storage**. - -Capabilities: +## Prerequisites -- Generates embeddings -- Stores vector memory -- Retrieves relevant knowledge using cosine similarity +- Python 3.12+ +- OpenRouter API key (free tier works): https://openrouter.ai --- -# ๐Ÿ“ฆ Project Structure +## Installation + ```bash -bindu-collaborative-agents -โ”‚ -โ”œโ”€โ”€ coordinator_agent.py -โ”œโ”€โ”€ research_agent.py -โ”œโ”€โ”€ memory_agent.py -โ”œโ”€โ”€ run_system.py -โ”‚ -โ”œโ”€โ”€ utils -โ”‚ โ””โ”€โ”€ semantic_memory.py -โ”‚ -โ””โ”€โ”€ requirements.txt -``` - -# โš™๏ธ Installation - -### 1๏ธโƒฃ Clone the repository git clone https://github.com/Subhajitdas99/bindu-collaborative-agents.git - cd bindu-collaborative-agents - - ---- - -### 2๏ธโƒฃ Install dependencies pip install -r requirements.txt +``` +Set your API key: ---- - -### 3๏ธโƒฃ Set API Key - -This project uses **OpenRouter for LLM access**. +```bash +# Linux/macOS export OPENROUTER_API_KEY="your-api-key" -Windows PowerShell: +# Windows PowerShell $env:OPENROUTER_API_KEY="your-api-key" +``` +Or create a `.env` file: ---- - -# โ–ถ๏ธ Run the System -python run_system.py +``` +OPENROUTER_API_KEY=your-api-key +BINDU_AUTHOR=your.email@example.com +``` +--- -Example: -User > What is the Bindu Framework? +## Running -Coordinator thinking... +Open **3 separate terminals** and run one agent in each: -๐Ÿ“š Stored memory: The Bindu Framework is a platform for interoperable AI agents... +**Terminal 1 โ€” Research Agent** +```bash +python research_agent.py +``` -Agent > The Bindu Framework enables agents to communicate within the Internet of Agents. +**Terminal 2 โ€” Memory Agent** +```bash +python memory_agent.py +``` +**Terminal 3 โ€” Coordinator Agent** +```bash +python coordinator_agent.py +``` --- -# ๐Ÿงช Example Interaction - - -User > What is the Bindu Framework? - -Coordinator thinking... -๐Ÿ“š Stored memory... +## Testing -Agent > Explanation about Bindu. +Send a query to the coordinator (Terminal 4): -User > What is Bindu again? +**Linux/macOS:** +```bash +curl -X POST http://localhost:3775/ \ + -H "Content-Type: application/json" \ + -d '{ + "jsonrpc": "2.0", + "method": "message/send", + "params": { + "message": { + "role": "user", + "parts": [{"kind": "text", "text": "What is Bindu?"}], + "kind": "message", + "messageId": "11111111-1111-1111-1111-111111111111", + "contextId": "11111111-1111-1111-1111-111111111112", + "taskId": "11111111-1111-1111-1111-111111111113" + }, + "configuration": {"acceptedOutputModes": ["application/json"]} + }, + "id": "11111111-1111-1111-1111-111111111114" + }' +``` -Coordinator thinking... -๐Ÿง  Retrieved knowledge from memory. +**Windows PowerShell:** +```powershell +Invoke-WebRequest -Uri "http://localhost:3775/" ` + -Method POST ` + -ContentType "application/json" ` + -UseBasicParsing ` + -Body '{"jsonrpc":"2.0","method":"message/send","params":{"message":{"role":"user","parts":[{"kind":"text","text":"What is Bindu?"}],"kind":"message","messageId":"11111111-1111-1111-1111-111111111111","contextId":"11111111-1111-1111-1111-111111111112","taskId":"11111111-1111-1111-1111-111111111113"},"configuration":{"acceptedOutputModes":["application/json"]}},"id":"11111111-1111-1111-1111-111111111114"}' | Select-Object -ExpandProperty Content +``` -Agent > (From Memory) The Bindu Framework... +Wait 15-20 seconds (research takes time), then poll for the result: +**Linux/macOS:** +```bash +curl -X POST http://localhost:3775/ \ + -H "Content-Type: application/json" \ + -d '{ + "jsonrpc": "2.0", + "method": "tasks/get", + "params": {"taskId": "11111111-1111-1111-1111-111111111113"}, + "id": "11111111-1111-1111-1111-111111111115" + }' +``` -This demonstrates **semantic memory retrieval**. +**Windows PowerShell:** +```powershell +Invoke-WebRequest -Uri "http://localhost:3775/" ` + -Method POST ` + -ContentType "application/json" ` + -UseBasicParsing ` + -Body '{"jsonrpc":"2.0","method":"tasks/get","params":{"taskId":"11111111-1111-1111-1111-111111111113"},"id":"11111111-1111-1111-1111-111111111115"}' | Select-Object -ExpandProperty Content +``` --- -# ๐ŸŒ Internet of Agents - -Bindu promotes a future where AI agents: - -- communicate with each other -- collaborate across systems -- exchange value -- operate autonomously +## Expected Output -This project demonstrates a **simple prototype of that vision**. - ---- - -# ๐Ÿ”ง Technologies Used +First query (cache miss โ€” researches the web): +```json +{ + "result": { + "status": {"state": "completed"}, + "artifacts": [{ + "parts": [{ + "kind": "text", + "text": "The Bindu AI Framework is designed to facilitate the creation of + intelligent and interoperable AI agents..." + }] + }] + } +} +``` -- Python -- OpenRouter API -- OpenAI Embeddings -- NumPy -- Vector Similarity Search +Second identical query (cache hit โ€” served from memory instantly): +```json +{ + "result": { + "artifacts": [{ + "parts": [{"kind": "text", "text": "(From Memory) The Bindu AI Framework..."}] + }] + } +} +``` --- -# ๐ŸŽฏ Use Cases - -This architecture can be extended to build: +## What This Demonstrates -- Autonomous research agents -- Collaborative AI assistants -- Knowledge-learning AI systems -- Multi-agent decision systems +- **Agent-to-Agent (A2A) communication** over HTTP using the Bindu protocol +- **DID identity** โ€” each agent gets a unique Decentralized Identifier +- **Semantic memory** โ€” knowledge retrieved by meaning, not keyword matching +- **Coordinator pattern** โ€” orchestration without tight coupling +- **Internet of Agents** โ€” agents discovering and calling each other --- -# ๐Ÿ† Bindu AI Agent Challenge - -This project was created for the **Bindu AI Agent Competition** celebrating **International Women's Day**. - -Goal: +## Project Structure -Build an AI agent system demonstrating the **Internet of Agents**. +``` +collaborative-agents/ +โ”œโ”€โ”€ coordinator_agent.py โ€” orchestrates research + memory agents +โ”œโ”€โ”€ research_agent.py โ€” web search via DuckDuckGo +โ”œโ”€โ”€ memory_agent.py โ€” semantic memory store/retrieve +โ”œโ”€โ”€ requirements.txt +โ”œโ”€โ”€ .env โ€” API keys (not committed) +โ”œโ”€โ”€ .gitignore +โ””โ”€โ”€ utils/ + โ””โ”€โ”€ semantic_memory.py โ€” embeddings + cosine similarity +``` --- -# ๐Ÿ“š Resources +## Technologies -Bindu Documentation -https://docs.getbindu.com - -Bindu GitHub -https://github.com/GetBindu/Bindu +- [Bindu](https://github.com/getbindu/bindu) โ€” Internet of Agents framework +- [Agno](https://github.com/agno-agi/agno) โ€” agent framework +- [OpenRouter](https://openrouter.ai) โ€” LLM + embeddings API +- [DuckDuckGo](https://pypi.org/project/duckduckgo-search/) โ€” web search +- NumPy โ€” cosine similarity computation --- -# ๐Ÿ‘จโ€๐Ÿ’ป Author +## Author **Subhajit Das** -Final Year B.Tech AI/ML Student +Final Year B.Tech AI/ML Student Interested in Multi-Agent Systems, AI Infrastructure, and Autonomous Agents. ---- - -# โญ Support - -If you found this project interesting: - -โญ Star the repository -๐Ÿš€ Share with the AI community - -Let's build the **Internet of Agents** together. \ No newline at end of file +GitHub: [@Subhajitdas99](https://github.com/Subhajitdas99) \ No newline at end of file