Zing Forum

Reading

TwistedCollab: A Local-First AI Agent Research Assistant

A fully self-hosted browser application that collaborates with local large language models via multi-agent workflows to provide cloud-independent research assistance. It integrates the TwistedPair rhetorical transformation engine and supports features like RAG retrieval, literature review, and debate analysis.

本地LLM智能体工作流RAG检索TwistedPair科研助手多智能体系统本地优先OllamaFAISS修辞变形
Published 2026-04-22 23:14Recent activity 2026-04-22 23:19Estimated read 7 min
TwistedCollab: A Local-First AI Agent Research Assistant
1

Section 01

TwistedCollab: Local-First AI Agent Research Assistant (Main Guide)

TwistedCollab Overview

TwistedCollab is a fully self-hosted browser application that serves as a local-first AI research assistant. It uses multi-agent workflows and local large language models (LLMs) to provide cloud-free support for research tasks. Key features include:

  • Integration with the TwistedPair rhetorical transformation engine
  • RAG retrieval, literature review, and debate analysis capabilities
  • Zero cloud dependency to ensure data privacy and local control

Its core mission is to create a unified workspace for managing research data, documents, and creative ideas without relying on external cloud services.

2

Section 02

Project Background & Core Philosophy

Background & Core Idea

TwistedCollab was developed by satoruisaka to meet personal research needs. The developer identified that cloud-based AI tools were uneconomical and insecure for handling large volumes of sensitive research data. The core philosophy is:

  • Build a local workspace to manage data, documents, and creativity
  • Leverage local LLMs for complex language processing tasks
  • Eliminate cloud dependency to protect privacy and reduce costs

The project focuses on supporting iterative thinking and creative ideation, which are central to research work.

3

Section 03

System Architecture & Tech Stack

Architecture & Tech Stack

TwistedCollab uses a browser + FastAPI server architecture:

  • Frontend: Pure HTML/JS app (communicates via SSE and REST)
  • Backend: Python 3.10+ with core components:
    • ChatManager (session lifecycle, prompt assembly)
    • RetrievalManager (FAISS semantic search + SQLite FTS5 full-text search)
    • WebSearchClient (Brave API, DuckDuckGo)
    • OllamaClient (local LLM calls via Ollama REST API)
    • TwistedPairClient (rhetorical engine integration)
    • Skill System (YAML-defined multi-agent workflows)

Supported local models: ministral-3:14b, gemma4:26b, qwen3-coder:30b, deepseek-r1:8b. Runs on RTX 5090 for 14B-30B models.

4

Section 04

Core Function Modules

Key Functions

  1. RAG & Multi-source Retrieval: Supports 12 local data sources (literature PDFs, personal works, uploads, etc.) with dual index (FAISS semantic + FTS5 keyword search).
  2. Multi-agent Workflows: Collab Tab enables YAML-defined skills (literature search, review, document comment) executed in sub-processes with CPU resource limits.
  3. TwistedPair Engine: 3 adjustable knobs:
    • MODE (6 types: INVERT_ER, SO_WHAT_ER, etc.)
    • TONE (5 styles: NEUTRAL, TECHNICAL, etc.)
    • GAIN (10 levels: 1-3 factual, 7-10 creative)
  4. Ecosystem Integration: Works with TwistedCore, TwistedDebate, TwistedDraw, and other Twisted services.
5

Section 05

Typical Workflow Example

Daily Usage Workflow

The developer's typical day with TwistedCollab:

  1. Morning: Read NewsAgent and TwistedNews emails for global updates.
  2. Launch TwistedCollab:
    • Search Tab: Brainstorm with LLM + real-time web/doc retrieval
    • Notes Tab: Record new ideas or review old notes
    • Session Tab: Resume previous creative discussions
    • Collab Tab: Run agent workflows (literature search, review)
    • Tools Tab: Use Twisted services for deep analysis
  3. For new workflows: Code in VS Code (Python + YAML) then restart the server.
6

Section 06

Technical Highlights & Innovations

Technical Innovations

  1. Fully Local: Zero cloud dependency for model inference and data storage (privacy protection).
  2. Dual Index Retrieval: Combines FAISS semantic search and SQLite FTS5 for comprehensive recall.
  3. TwistedPair Paradigm: Treats LLM output as adjustable signal processing (mode, tone, gain).
  4. Modular Skills: YAML-defined workflows with sub-process execution and resource limits.
  5. Ecosystem Design: Integrated with multiple Twisted services to form a local AI toolchain.
7

Section 07

Application Scenarios & Insights

Use Cases & Insights

Applicable Scenarios:

  • Academic researchers (literature management, data privacy)
  • Knowledge workers (personal knowledge base)
  • Creative writers (diverse text styles)
  • Local AI enthusiasts (custom workflows)

Insights:

  • Local LLMs (14B-30B) on RTX5090 can support complex research tasks.
  • TwistedPair's signal processing analogy offers new LLM interaction design ideas.
  • The modular architecture provides a reference for building personal AI workspaces.