uniichat README

README проекта с github.com/VictorTaelin/uniichat. Одним файлом markdown: README.md.

UniiChat

▶ Watch the announcement video

This repo is vibe-coded. AI agents wrote nearly all of it, and AI agents reviewed it. Read it, run it and fork it as such: expect bugs.

UniiChat is an AI agent with one chat that never ends. There is no "new chat" button: you talk to the same agent for days, weeks, years, and it remembers. The hosted version is at https://uniichat.com. This is its source, to run your own server on your own API keys.

How it works

The design is in the header comment of each file. Start with Memory.ts (the tree and the view), Server.ts (the chat, turns, workers) and AskAI.ts (model calls and the cache).

Run it

You need Bun and an Anthropic API key (or an OpenAI one, below).

export ANTHROPIC_API_KEY=sk-ant-...
bun Server.ts                    # http://127.0.0.1:8788, data in ~/.unii

Then open http://127.0.0.1:8788 and type your email. With no mail key set, the server prints the sign-in link in its output: open it. Or chat from a terminal:

bun Term.ts http://127.0.0.1:8788

It asks for your email, the server prints a link, and the page it opens asks for the code the terminal shows. bun Term.ts help lists the rest.

Other commands:

bun run test                     # the tests, each file on its own
bun run web                      # rebuilds web/app.js from web/src
bun build --compile Term.ts --outfile unii
                                 # one `unii` executable; `unii serve`
                                 # runs the server it carries

Your chats live in ~/.unii/users/, one JSON line per message (main/) and per summary (tree/). They are the memory: back them up.

Config

~/.unii/config.json (optional; the dir is $UNII_DIR). Each key may also be set as the variable UNII_<KEY>:

Keys are read from the environment: ANTHROPIC_API_KEY, OPENAI_API_KEY, RESEND_API_KEY (to email sign-in links; none: they print), APNS_KEY.

With only an OpenAI key, set vendors, pick and compactor to openai-api models, e.g. UNII_VENDORS=openai-api UNII_PICK=openai-api:gpt-6.1-sol:medium:slow UNII_COMPACTOR=openai-api:gpt-6-luna:high:slow.

A self-hosted server is free: it bills no one, shows no prices, and calls only the model vendors. Billing.ts is the one place a hosted server plugs in its billing (uniichat.com sells credits; this repo has none).

The unii terminal

web/install.sh (served at /install.sh) runs the official installer, which installs the released unii executable. unii alone opens uniichat.com; unii <url> opens any server. Run with UNII_COMPUTER=1 on a Mac, the agent may use its screen (it compiles Computer.swift with swiftc; macOS asks for Screen Recording and Accessibility).

Telemetry: once a day the unii terminal asks bend-lang.com's /check for the latest version (Term.ts update_check), sending its version, OS and CPU type, no account and no id; it also says whether this computer has ever self-hosted (set for good the first time it runs unii serve or opens a server other than uniichat.com). It is the one call a self-hosted UniiChat makes to us. UNII_NO_TELEMETRY=1 turns it off.

License

Apache-2.0 (LICENSE). Copyright 2026 Higher Order Company.

uniichat (VictorTaelin/uniichat)

Ищем в базе…

Что это такое?UniiChat — это ИИ-агент, который работает на вашем собственном сервере. Вы общаетесь с ним в одном бесконечном диалоге: кнопки «новый чат» нет, и он помнит всё на протяжении дней, недель и лет благодаря встроенному дереву памяти.
Это чат-приложение или фреймворк, на котором я буду что-то строить?Это серверное приложение, которое вы разворачиваете у себя: бэкенд на TypeScript/Bun. К нему может подключаться любое количество клиентов — вкладка браузера или терминальный клиент 'unii' — и каждый из них показывает один и тот же текущий диалог в реальном времени.
Как это запустить?Клонируйте репозиторий и запустите 'bun Server.ts', чтобы стартовать сервер, или 'bun Term.ts', чтобы общаться из терминала. Также можно собрать отдельный исполняемый файл 'unii' командой 'bun build --compile Term.ts --outfile unii'.
Нужны ли для работы Bun и ключ API Anthropic?Да: по умолчанию нужны установленный Bun и ключ API Anthropic. Можно перейти на ключ OpenAI, изменив настройки vendor, pick и compactor.
Достаточно ли проект стабилен, чтобы использовать его как ежедневного агента?В README прямо сказано, что весь проект написан в стиле «вайб-кодинга»: почти всё создано и проверено ИИ-агентами, так что стоит ожидать багов.
Работает ли это на Windows и Linux, или только на macOS?Так как проект работает на Bun, он запускается на macOS, Linux и Windows. Только необязательная функция управления экраном Mac доступна лишь на macOS.
Покидают ли мои данные чатов компьютер?Чаты сохраняются локально, в виде строк JSON в ~/.unii/users/. Единственный исходящий запрос, который делает собственный сервер, — ежедневная проверка версии с пингом на bend-lang.com без аккаунта и идентификатора; её можно отключить.
Как на самом деле работает дерево памяти?Каждое сообщение сжимается в одну строку, а соседние строки постоянно попарно объединяются в бинарное дерево. Поэтому каждый запрос видит последние сообщения целиком, а более старые — в виде сжатых, укрупнённых сводок. Ничего не удаляется: агент может «заглянуть» внутрь любой сводки и увидеть исходные сообщения, из которых она появилась.
Можно ли импортировать мои старые переписки из ChatGPT или Claude?Да, UniiChat умеет импортировать папки Claude Code и Codex, а также экспорт переписок с сайтов Claude и ChatGPT, и они попадают в дерево памяти.
Может ли агент управлять экраном моего Mac?Да: если запустить с переменной UNIICOMPUTER=1 на macOS, агент сможет управлять экраном. Он компилирует Computer.swift через swiftc, а macOS запросит разрешения «Запись экрана» и «Универсальный доступ».
Есть ли облачная версия, которой можно пользоваться вместо собственного сервера?Да, uniichat.com — это облачная версия, которая продаёт кредиты для оплаты. Собственный сервер бесплатен и обращается только к поставщикам моделей, которые вы настроили.
Какие есть похожие проекты?brigade, Raven, ruflo, OptMem, aichat, whirl, Athena-Public, pi-optchat
Автор
VictorTaelin
Размер
0.2 MB
Звёзды
678
Обновлён
КоммитOct 19
Возраст
30 д
Коммиты · 90 дней