#250·Memori

[Feature] Support for Local & Custom OpenAI-Compatible Endpoints (Ollama/vLLM)

Author: TrombokenduShivCreated Jan 2, 2026Updated Jul 7, 2026
Labelsenhancement

Is your feature request related to a problem?

Currently, the OpenAIIntegration appears to default to the official OpenAI API (api.openai.com). While this works perfectly for standard use cases, many developers (myself included) are moving towards local inference using tools like Ollama, LocalAI, or vLLM for privacy and cost reasons. These tools often expose an OpenAI-compatible endpoint (e.g., http://localhost:11434/v1), but Memori doesn't currently offer a streamlined way to point the client to these custom URLs.

The Solution

I propose updating the Memori configuration and OpenAIIntegration to accept an optional base_url parameter. Specifically:

  1. Update ConfigManager (and Memori init) to accept a base_url argument.
  2. Pass this base_url into the openai.Client instantiation within memori/integrations/openai_integration.py.

This would allow users to initialize Memori with local models effortlessly:

# Example Usage
memori = Memori(
    api_key="ollama", 
    base_url="http://localhost:11434/v1" # Local endpoint
)

Alternatives Considered

I have analyzed the codebase and believe this change is primarily isolated to openai_integration.py and the configuration logic. I would be happy to implement this myself and submit a PR. Please let me know if this aligns with the roadmap!

Affected Components

Other

Participation

  • I am willing to submit a pull request for this feature.