Skip to content

feat: integrate LazyLLM to provide more llm services#265

Merged
evan-ak merged 16 commits intoNevaMind-AI:mainfrom
uestcsh917-art:feat/integrate-lazyllm
Jan 28, 2026
Merged

feat: integrate LazyLLM to provide more llm services#265
evan-ak merged 16 commits intoNevaMind-AI:mainfrom
uestcsh917-art:feat/integrate-lazyllm

Conversation

@uestcsh917-art
Copy link
Contributor

Feature Overview

  • Add LazyLLM backend to support to extend MemU's multi-model AI service capabilities, compatible with LLM/VLM/Embed/STT model types.
  • Provide 1 complete example programexamples/example_5_with_lazyllm_client.py covering conversation memory processing, skill extraction, and multimodal memory generation scenarios.
  • Provide 1 test file tests/test_lazyllm.pyto verify LazyLLM backend configuration and basic functionality

Core Changes

1. New LazyLLM Client Implementation (src/memu/llm/lazyllm_client.py)

  • Implemented LazyLLMClient class with a unified interface.
  • Support 4 model capabilities and multiple model providers:
    • Source(model service provider): Default qwen
    • LLM (Text Generation/Summarization): Default qwen-plus, provides summarize() method
    • VLM (Vision Language Understanding): Default qwen-vl-plus, provides vision() method
    • Embed (Text Embedding): Default text-embedding-v3, provides embed() method
    • STT (Speech-to-Text): Default qwen-audio-turbo, provides transcribe() method
  • Key Features:
    • Asynchronous call support.
    • flexible providers/models configuration.

2. One New Example Programs

Example File Functional Scenario Output Path
examples/example_5_with_lazyllm_client.py
1. Multi-conversation file processing → Memory category generation
2. Workflow/agent logs → Skill extraction (task guidelines)
3. Document + image multimodal processing → Unified memory categories
examples/output/lazyllm_example/

Testing Steps

Prerequisites

  • Install lazyllm dependencies: pip install lazyllm
  • Configure API key according to the source and model configuration in tests/test_lazyllm.py,Defaut qwen
    export MEMU_QWEN_API_KEY='your-api-key'

Test Commands

# Run unit tests
python tests/test_lazyllm.py

# Run example programs (verify end-to-end functionality)
python examples/example_5_with_lazyllm_client.py
@evan-ak evan-ak force-pushed the feat/integrate-lazyllm branch from 8b3a81a to de4e0ec Compare January 28, 2026 15:37
@evan-ak evan-ak force-pushed the feat/integrate-lazyllm branch from 86c19c3 to 288347f Compare January 28, 2026 16:02
@evan-ak evan-ak force-pushed the feat/integrate-lazyllm branch from 4fe172c to bf5006f Compare January 28, 2026 16:10
@evan-ak evan-ak merged commit c03f639 into NevaMind-AI:main Jan 28, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants