# VRIN Memory Orchestration
AI-powered knowledge management and retrieval system that provides human-like neural memory capabilities.
## Quick Start
```bash
pip install vrin
```
```python
from vrin import VRIN
# Create VRIN client with your API key
vrin = VRIN(api_key="your_api_key_here")
# Insert knowledge into memory
vrin.insert("Python is a programming language created by Guido van Rossum in 1991")
# Retrieve knowledge using natural language queries
results = vrin.query("What is Python?")
print(results)
```
That's it! VRIN automatically handles:
- ✅ Fact extraction and knowledge structuring
- ✅ Neural memory retrieval with semantic search
- ✅ Temporal context and conflict resolution
- ✅ Pronoun resolution for clarity
- ✅ User isolation and security
## Features
### 🧠 **Neural Memory System**
- Human-like memory retrieval using semantic similarity
- Automatic fact extraction from natural language
- Temporal context awareness and conflict resolution
### 🔍 **Intelligent Search**
- Natural language querying
- Semantic similarity matching
- Context-aware responses
- Anti-hallucination protection
### 🛡️ **Enterprise Security**
- User isolation and data privacy
- API key management
- Secure authentication
- Rate limiting and monitoring
### 📊 **Knowledge Graph Visualization**
- Interactive graph visualization
- Real-time knowledge mapping
- Relationship discovery
- Temporal fact tracking
## Installation
```bash
pip install vrin
```
## Basic Usage
### 1. Initialize the Client
```python
from vrin import VRIN
# Option 1: Pass API key directly
vrin = VRIN(api_key="your_api_key_here")
# Option 2: Use environment variable
import os
os.environ["VRIN_API_KEY"] = "your_api_key_here"
vrin = VRIN()
```
### 2. Insert Knowledge
```python
# Insert single piece of knowledge
result = vrin.insert("Python is a high-level programming language created by Guido van Rossum")
# Insert multiple pieces of knowledge
texts = [
"Python was first released in 1991",
"Python is known for its simplicity and readability",
"Guido van Rossum is the creator of Python"
]
results = vrin.insert_multiple(texts)
```
### 3. Query Knowledge
```python
# Basic query
results = vrin.query("What is Python?")
# Advanced query with LLM processing
results = vrin.query_advanced("Explain the history of Python programming language")
```
### 4. Access Knowledge Graph
```python
# Get complete knowledge graph
graph = vrin.get_knowledge_graph()
nodes = graph['data']['nodes']
edges = graph['data']['edges']
```
## API Reference
### Core Methods
#### `insert(text: str)`
Insert knowledge into the system.
```python
result = vrin.insert("Knowledge text here")
```
#### `query(query: str)`
Query knowledge using natural language.
```python
results = vrin.query("What is the capital of France?")
```
#### `get_knowledge_graph()`
Retrieve the complete knowledge graph.
```python
graph = vrin.get_knowledge_graph()
```
### Advanced Methods
#### `query_advanced(query: str)`
Advanced query with LLM processing (may timeout for complex queries).
```python
results = vrin.query_advanced("Complex query with reasoning")
```
#### `insert_multiple(texts: List[str])`
Insert multiple pieces of knowledge at once.
```python
results = vrin.insert_multiple(["Text 1", "Text 2", "Text 3"])
```
#### `query_multiple(queries: List[str])`
Query multiple questions at once.
```python
results = vrin.query_multiple(["Question 1", "Question 2"])
```
## Error Handling
The SDK provides specific exception types for different error scenarios:
```python
from vrin import VRINError, VRINAuthenticationError, VRINRateLimitError
try:
result = vrin.query("What is Python?")
except VRINAuthenticationError:
print("Invalid API key")
except VRINRateLimitError:
print("Rate limit exceeded")
except VRINError as e:
print(f"General error: {e}")
```
## Configuration
### Environment Variables
- `VRIN_API_KEY`: Your VRIN API key
- `VRIN_BASE_URL`: Custom API endpoint (optional)
### Client Configuration
```python
vrin = VRIN(
api_key="your_api_key",
base_url="https://custom-endpoint.com", # Optional
timeout=30, # Request timeout in seconds
max_retries=3 # Maximum retry attempts
)
```
## Examples
### Basic Knowledge Management
```python
from vrin import VRIN
vrin = VRIN(api_key="your_api_key")
# Store knowledge about a topic
vrin.insert("Machine learning is a subset of artificial intelligence that enables computers to learn without being explicitly programmed.")
# Query the knowledge
results = vrin.query("What is machine learning?")
print(results)
```
### Multi-step Knowledge Building
```python
# Build knowledge incrementally
vrin.insert("John is a software engineer")
vrin.insert("John works at Google")
vrin.insert("Google is a technology company")
# Query complex relationships
results = vrin.query("Where does John work?")
print(results)
```
### Knowledge Graph Analysis
```python
# Get the complete knowledge graph
graph = vrin.get_knowledge_graph()
# Analyze the structure
nodes = graph['data']['nodes']
edges = graph['data']['edges']
print(f"Knowledge graph contains {len(nodes)} entities and {len(edges)} relationships")
```
## Contributing
We welcome contributions! Please see our [Contributing Guide](CONTRIBUTING.md) for details.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## Support
- 📧 Email: contact@vrin.ai
- 📖 Documentation: https://docs.vrin.ai
- 🐛 Issues: https://github.com/vrin-ai/vrin-python/issues
Raw data
{
"_id": null,
"home_page": null,
"name": "vrin",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "VRIN Team <vedant@vrin.cloud>",
"keywords": "ai, knowledge-graph, memory, orchestration, context, retrieval",
"author": null,
"author_email": "VRIN Team <vedant@vrin.cloud>",
"download_url": "https://files.pythonhosted.org/packages/3b/c9/1589d4df6ed33a31580095c634dd7644b00351aee2fa3d684ee298ae8fe7/vrin-0.1.2.tar.gz",
"platform": null,
"description": "# VRIN Memory Orchestration\n\nAI-powered knowledge management and retrieval system that provides human-like neural memory capabilities.\n\n## Quick Start\n\n```bash\npip install vrin\n```\n\n```python\nfrom vrin import VRIN\n\n# Create VRIN client with your API key\nvrin = VRIN(api_key=\"your_api_key_here\")\n\n# Insert knowledge into memory\nvrin.insert(\"Python is a programming language created by Guido van Rossum in 1991\")\n\n# Retrieve knowledge using natural language queries\nresults = vrin.query(\"What is Python?\")\nprint(results)\n```\n\nThat's it! VRIN automatically handles:\n- \u2705 Fact extraction and knowledge structuring\n- \u2705 Neural memory retrieval with semantic search\n- \u2705 Temporal context and conflict resolution\n- \u2705 Pronoun resolution for clarity\n- \u2705 User isolation and security\n\n## Features\n\n### \ud83e\udde0 **Neural Memory System**\n- Human-like memory retrieval using semantic similarity\n- Automatic fact extraction from natural language\n- Temporal context awareness and conflict resolution\n\n### \ud83d\udd0d **Intelligent Search**\n- Natural language querying\n- Semantic similarity matching\n- Context-aware responses\n- Anti-hallucination protection\n\n### \ud83d\udee1\ufe0f **Enterprise Security**\n- User isolation and data privacy\n- API key management\n- Secure authentication\n- Rate limiting and monitoring\n\n### \ud83d\udcca **Knowledge Graph Visualization**\n- Interactive graph visualization\n- Real-time knowledge mapping\n- Relationship discovery\n- Temporal fact tracking\n\n## Installation\n\n```bash\npip install vrin\n```\n\n## Basic Usage\n\n### 1. Initialize the Client\n\n```python\nfrom vrin import VRIN\n\n# Option 1: Pass API key directly\nvrin = VRIN(api_key=\"your_api_key_here\")\n\n# Option 2: Use environment variable\nimport os\nos.environ[\"VRIN_API_KEY\"] = \"your_api_key_here\"\nvrin = VRIN()\n```\n\n### 2. Insert Knowledge\n\n```python\n# Insert single piece of knowledge\nresult = vrin.insert(\"Python is a high-level programming language created by Guido van Rossum\")\n\n# Insert multiple pieces of knowledge\ntexts = [\n \"Python was first released in 1991\",\n \"Python is known for its simplicity and readability\",\n \"Guido van Rossum is the creator of Python\"\n]\nresults = vrin.insert_multiple(texts)\n```\n\n### 3. Query Knowledge\n\n```python\n# Basic query\nresults = vrin.query(\"What is Python?\")\n\n# Advanced query with LLM processing\nresults = vrin.query_advanced(\"Explain the history of Python programming language\")\n```\n\n### 4. Access Knowledge Graph\n\n```python\n# Get complete knowledge graph\ngraph = vrin.get_knowledge_graph()\nnodes = graph['data']['nodes']\nedges = graph['data']['edges']\n```\n\n## API Reference\n\n### Core Methods\n\n#### `insert(text: str)`\nInsert knowledge into the system.\n\n```python\nresult = vrin.insert(\"Knowledge text here\")\n```\n\n#### `query(query: str)`\nQuery knowledge using natural language.\n\n```python\nresults = vrin.query(\"What is the capital of France?\")\n```\n\n#### `get_knowledge_graph()`\nRetrieve the complete knowledge graph.\n\n```python\ngraph = vrin.get_knowledge_graph()\n```\n\n### Advanced Methods\n\n#### `query_advanced(query: str)`\nAdvanced query with LLM processing (may timeout for complex queries).\n\n```python\nresults = vrin.query_advanced(\"Complex query with reasoning\")\n```\n\n#### `insert_multiple(texts: List[str])`\nInsert multiple pieces of knowledge at once.\n\n```python\nresults = vrin.insert_multiple([\"Text 1\", \"Text 2\", \"Text 3\"])\n```\n\n#### `query_multiple(queries: List[str])`\nQuery multiple questions at once.\n\n```python\nresults = vrin.query_multiple([\"Question 1\", \"Question 2\"])\n```\n\n## Error Handling\n\nThe SDK provides specific exception types for different error scenarios:\n\n```python\nfrom vrin import VRINError, VRINAuthenticationError, VRINRateLimitError\n\ntry:\n result = vrin.query(\"What is Python?\")\nexcept VRINAuthenticationError:\n print(\"Invalid API key\")\nexcept VRINRateLimitError:\n print(\"Rate limit exceeded\")\nexcept VRINError as e:\n print(f\"General error: {e}\")\n```\n\n## Configuration\n\n### Environment Variables\n\n- `VRIN_API_KEY`: Your VRIN API key\n- `VRIN_BASE_URL`: Custom API endpoint (optional)\n\n### Client Configuration\n\n```python\nvrin = VRIN(\n api_key=\"your_api_key\",\n base_url=\"https://custom-endpoint.com\", # Optional\n timeout=30, # Request timeout in seconds\n max_retries=3 # Maximum retry attempts\n)\n```\n\n## Examples\n\n### Basic Knowledge Management\n\n```python\nfrom vrin import VRIN\n\nvrin = VRIN(api_key=\"your_api_key\")\n\n# Store knowledge about a topic\nvrin.insert(\"Machine learning is a subset of artificial intelligence that enables computers to learn without being explicitly programmed.\")\n\n# Query the knowledge\nresults = vrin.query(\"What is machine learning?\")\nprint(results)\n```\n\n### Multi-step Knowledge Building\n\n```python\n# Build knowledge incrementally\nvrin.insert(\"John is a software engineer\")\nvrin.insert(\"John works at Google\")\nvrin.insert(\"Google is a technology company\")\n\n# Query complex relationships\nresults = vrin.query(\"Where does John work?\")\nprint(results)\n```\n\n### Knowledge Graph Analysis\n\n```python\n# Get the complete knowledge graph\ngraph = vrin.get_knowledge_graph()\n\n# Analyze the structure\nnodes = graph['data']['nodes']\nedges = graph['data']['edges']\n\nprint(f\"Knowledge graph contains {len(nodes)} entities and {len(edges)} relationships\")\n```\n\n## Contributing\n\nWe welcome contributions! Please see our [Contributing Guide](CONTRIBUTING.md) for details.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Support\n\n- \ud83d\udce7 Email: contact@vrin.ai\n- \ud83d\udcd6 Documentation: https://docs.vrin.ai\n- \ud83d\udc1b Issues: https://github.com/vrin-ai/vrin-python/issues \n",
"bugtrack_url": null,
"license": null,
"summary": "AI-powered knowledge management and retrieval system",
"version": "0.1.2",
"project_urls": {
"Bug Tracker": "https://github.com/vrin-ai/vrin-python/issues",
"Documentation": "https://docs.vrin.ai",
"Homepage": "https://github.com/vrin-ai/vrin-python",
"Repository": "https://github.com/vrin-ai/vrin-python"
},
"split_keywords": [
"ai",
" knowledge-graph",
" memory",
" orchestration",
" context",
" retrieval"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "93f89ee93fe9135cd1fededb0ed85c6cb5884d939577162001f008137e6c40d4",
"md5": "51331353c85b63c68d81d167294166ca",
"sha256": "bddf19e15976088fb693960d8253ae2a6bc54322aff34f80a6896c8291922ebb"
},
"downloads": -1,
"filename": "vrin-0.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "51331353c85b63c68d81d167294166ca",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 12225,
"upload_time": "2025-08-02T06:33:20",
"upload_time_iso_8601": "2025-08-02T06:33:20.227088Z",
"url": "https://files.pythonhosted.org/packages/93/f8/9ee93fe9135cd1fededb0ed85c6cb5884d939577162001f008137e6c40d4/vrin-0.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "3bc91589d4df6ed33a31580095c634dd7644b00351aee2fa3d684ee298ae8fe7",
"md5": "617d96a7be74626afdbe6ec8a035185d",
"sha256": "2cb2633a518a8ee40201a1a7dcb4fc7071ce78bc858b0d04049e4a3caab3cf07"
},
"downloads": -1,
"filename": "vrin-0.1.2.tar.gz",
"has_sig": false,
"md5_digest": "617d96a7be74626afdbe6ec8a035185d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 13209,
"upload_time": "2025-08-02T06:33:21",
"upload_time_iso_8601": "2025-08-02T06:33:21.382498Z",
"url": "https://files.pythonhosted.org/packages/3b/c9/1589d4df6ed33a31580095c634dd7644b00351aee2fa3d684ee298ae8fe7/vrin-0.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-02 06:33:21",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "vrin-ai",
"github_project": "vrin-python",
"github_not_found": true,
"lcname": "vrin"
}