feat: SWIRL federated search and document import

🟢 open · #14 · willchen96/mike ← sid-swirl/mike · opened 25d ago by sid-swirl · +421-52 across 5 files · ↗ on GitHub

From the PR description

feat: SWIRL federated search and document import

Description: Two new tools for the project assistant, powered by a SWIRL federated search backend:

  1. search_external

Queries live external data sources and returns ranked results with title, snippet, URL, and source name. Useful for case law, regulations, sanctions lists, company filings, or any source not in the uploaded project documents. Supports scoping to specific Microsoft 365 sources via query prefixes:

onedrive: - user's OneDrive files sharepoint: - SharePoint sites and document libraries outlook: - Outlook email teams: - Teams messages and files microsoft: - all configured M365 sources at once

  1. import_document

Imports a document from a search result URL directly into the current project. Supports PDF, DOCX, and DOC. For authenticated sources (SharePoint, OneDrive, etc.) the fetch is proxied through SWIRL, which manages the OAuth token - no credentials are exposed to the LLM.

After a successful import the project sidebar refreshes automatically without a page reload.

Setup Add to backend/.env: SWIRL_URL=http://your-swirl-host:8000 SWIRL_TOKEN=your-swirl-api-token # DRF token auth

or

SWIRL_USERNAME= # Basic auth (takes precedence) SWIRL_PASSWORD=

Both variables are optional. When SWIRL_URL is absent the tools are still registered but return a friendly "external search is not configured" message rather than erroring.

Our analysis

Add SWIRL federated search and one-click document import — read the full analysis →

Think the analysis missed something the PR description covers?

Capture this PR into my fork

Download a Markdown prompt that tells Claude how to port every commit in this PR into your working tree. Run it via claude -p < capture-pull-14.md from inside the repo you want the changes in.

⬇ Download capture-pull-14.md