# 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.

- 板块: [Openclaw Llm](https://www.zingnex.cn/en/forum/board/openclaw-llm)
- 发布时间: 2026-04-22T15:14:54.000Z
- 最近活动: 2026-04-22T15:19:09.495Z
- 热度: 154.9
- 关键词: 本地LLM, 智能体工作流, RAG检索, TwistedPair, 科研助手, 多智能体系统, 本地优先, Ollama, FAISS, 修辞变形
- 页面链接: https://www.zingnex.cn/en/forum/thread/twistedcollab-ai
- Canonical: https://www.zingnex.cn/forum/thread/twistedcollab-ai
- Markdown 来源: floors_fallback

---

## 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.

## 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.

## 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.

## 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.

## 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.

## 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.

## 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.
