Metadata-Version: 2.4
Name: unitbook
Version: 0.1.8
Summary: Unitized fund ledger for a pooled trading account: signed append-only log, units per investor, NAV per unit, fee by unit burn.
Author: Gesamt
Author-email: Gesamt <235901389+confirmxxx@users.noreply.github.com>
License-Expression: LicenseRef-Proprietary
License-File: LICENSE
Requires-Dist: pynacl
Requires-Dist: openpyxl
Requires-Dist: mcp>=2.1,<3
Requires-Dist: rich
Requires-Dist: prompt-toolkit
Requires-Dist: sparklines>=1.0.0
Requires-Dist: questionary>=2.1.1
Requires-Python: >=3.12
Description-Content-Type: text/markdown

# GESAMT//Unitbook

[![PyPI](https://img.shields.io/pypi/v/unitbook)](https://pypi.org/project/unitbook/)

## What it is

You trade one exchange account, and part of the money in it belongs to other people.
Unitbook tracks who owns how many shares of that account and prices those shares every
time you record the balance. It takes your fee by giving you shares instead of moving
cash, and writes every step into a signed, append-only log that anyone can replay and
check. It answers one question exactly: if an investor pulled out today, how much would
they get, and can they prove it.

## Who it is for

One trader running a shared account for a handful of investors, on a laptop, with no
engineer on staff. No server, no database, no exchange API key, no account to open
anywhere.

## How the owner uses it

Three doors, all writing the same log.

**An agent**, by voice or text: "Balance is 132,000 today", "Petya put in 20,000", "Send
Vasya his statement." It turns the sentence into a proposed entry, shows you the
consequence, and writes only after you say yes.

**A terminal session.** Stand in the book's folder and run `unitbook` with nothing after
it: a line at the bottom shows the book, the price per share, how many investors, and
today's balance, and you type a word — `deposit`, `withdraw`, `balance` — and answer what
it asks.

**A spreadsheet.** Add a row to `journal.xlsx`, double-click `Unitbook.command` next to
it. It shows you what the row will do and waits for Enter.

## What an investor gets

A one-page statement that opens on a phone: balance, price per share, deposits and
withdrawals, a monthly return line, the manager's name and the date. Beside it, an xlsx
with the same numbers and the exact point in the log they were computed from. Either file
can be checked offline with `unitbook verify` — an investor never has to trust the person
who sent it.

## The fee, as it actually runs

N% of profit above the previous peak, taken every time the balance is recorded. No cash
moves — you're given shares instead, and the investor's shares shrink by the same value.
Each investor can be given their own rate.

## Install

- macOS: double-click the `.command` file you were sent.
- Anywhere else: `uv tool install unitbook`, then `unitbook setup <your code>`.
- Upgrade later: `uv tool upgrade unitbook`. Full detail, including Linux and PATH:
  [install](docs/install.md).

## The guarantees

- The log is signed and append-only — nobody, including whoever is running it, can edit
  a past entry, only append a reversal — and anybody can replay it from scratch and get
  the same numbers, which is what `verify` does, on an investor's own machine, offline.
- No server, no database, no account anywhere — your book is a folder of files you own,
  and nothing secret ships in the package: the signing key never leaves your machine and
  never touches the book folder.
- An agent driving the book is boxed in: it must record the balance before it can price
  money in or out, a number far outside the book's history is refused until you
  personally force it through, more than a handful of writes an hour is refused until you
  personally release it, every mistake is corrected by appending a reversal rather than
  editing anything, and every write leaves its own backup behind.

## Docs

[Install](docs/install.md) · [Owner guide](docs/owner-guide.md) ·
[Agent guide](docs/agent-guide.md) · [Concepts](docs/concepts.md) ·
[Investor verification](docs/investor-verify.md) · [FAQ](docs/faq.md) ·
[Roadmap](ROADMAP.md)

## Licence

Proprietary software, licensed to named people. Copyright (c) 2026 Gesamt Team. See
[LICENSE](LICENSE).

## О программе

Ты торгуешь на одном счёте, и часть денег на нём принадлежит другим людям. Unitbook
считает, кому сколько паёв этого счёта принадлежит, и переоценивает пай каждый раз, когда
ты вносишь баланс. Комиссию он берёт паями, а не деньгами, и записывает каждый шаг в
подписанный, только-дописываемый журнал, который любой может пересчитать и проверить. Он
отвечает ровно на один вопрос: если инвестор заберёт деньги сегодня, сколько он получит и
может ли он это доказать.

**Для кого.** Один трейдер, который ведёт общий счёт для нескольких инвесторов, с
ноутбука, без программиста в штате.

**Как это устроено.** Три двери, все пишут в один журнал. Агент, голосом или текстом:
«баланс сегодня 132 000», «Петя внёс 20 000», «пришли Васе выписку» — он предлагает
запись, показывает последствия и пишет только после твоего «да». Терминал: просто
`unitbook` без аргументов, дальше вопрос-ответ. Таблица: строка в `journal.xlsx`, двойной
клик по `Unitbook.command`.

**Что получает инвестор.** Одна страница, открывается на телефоне: баланс, цена пая,
взносы и выводы, доходность по месяцам, имя управляющего и дата. Рядом — xlsx с теми же
цифрами и точкой журнала, из которой они посчитаны. Любой файл проверяется офлайн —
`unitbook verify`.

**Комиссия.** N% от прибыли выше прошлого пика, берётся при каждой проверке баланса,
паями, а не деньгами. Ставка может быть своя для каждого инвестора.

**Установка.** На Mac — двойной клик по присланному `.command`; иначе — `uv tool install
unitbook`, затем `unitbook setup <код>`; обновление — `uv tool upgrade unitbook`.

**Гарантии.** Журнал подписан и только дописывается — прошлую запись нельзя исправить,
можно только дописать отмену. Кто угодно может пересчитать его с нуля и получить те же
цифры, офлайн. Ни сервера, ни базы данных, ни учётной записи — только папка с файлами;
ключ подписи никогда не покидает твою машину. Агент не может провести деньги, не записав
сначала баланс, не может протолкнуть число, сильно выходящее за историю книги, без твоего
личного подтверждения, не может писать быстрее заданного предела без твоего разрешения, и
каждая запись оставляет свою резервную копию.

**Лицензия.** Проприетарная, именная. См. [LICENSE](LICENSE).
