Metadata-Version: 2.4
Name: visual-base
Version: 0.2.0
Summary: A Bub distribution centered on Kimi as the default model and local screen-visual capture.
Project-URL: Homepage, https://github.com/oilbeater/visual-base
Project-URL: Repository, https://github.com/oilbeater/visual-base
Project-URL: Issues, https://github.com/oilbeater/visual-base/issues
Author-email: Mengxin Liu <liumengxinfly@gmail.com>
License: MIT License
        
        Copyright (c) 2026 Mengxin Liu
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: MacOS :: MacOS X
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Multimedia :: Video :: Capture
Classifier: Topic :: Software Development
Requires-Python: <4.0,>=3.12
Requires-Dist: bub<0.4,>=0.3.6
Requires-Dist: imageio-ffmpeg>=0.5.1
Requires-Dist: loguru>=0.7
Requires-Dist: pydantic-settings>=2.0
Description-Content-Type: text/markdown

# visual-base

> **The second brain from your eyes.**

Other "second brain" tools ask you to do the remembering — write the
note, hit the highlight, tag the page. Whatever you didn't capture is
gone; what you did is a biased sample.

`visual-base` records what your eyes actually land on — your screen,
continuously, as compressed video. The raw stream is the **single
source of truth**; every derived artifact — activity logs, search
indexes, future tool-use over the tape — comes *out* of it, never
replaces it. If it was on your screen, it's in the tape.

What ships:

- **`bub_eye`** — background screen recorder. macOS (Intel + Apple
  Silicon), hardware HEVC via `avfoundation`, ~10 MB per 15-min
  segment, near-zero CPU.
- **`bub_kimi`** — Kimi as the default agent for video understanding
  and daily-log generation.
- **`video-activity-log`** — turns any segment into an Obsidian-linkable
  daily log, one bullet per activity, with `[[wikilinks]]` on every
  site, app, person, and project it can identify.

## Install

```bash
uv tool install visual-base
```

`bub_eye`'s ffmpeg binary ships in the wheel via `imageio-ffmpeg`.
`kimi-cli` auto-installs as a separate uv tool on the first Kimi call.

Authenticate Kimi once. Either log in through the TUI (after `uv tool
install kimi-cli`):

```bash
kimi login
```

or set an API key via env vars:

```bash
cp .env.example .env   # then fill in BUB_KIMI_*
```

macOS will prompt for **Screen Recording permission** the first time
`bub_eye` spawns ffmpeg. The grant is path-specific — re-grant if you
switch to a system ffmpeg via `BUB_EYE_FFMPEG`.

### For local development

```bash
uv sync
cp .env.example .env
uv run visual-base --help
```

`just setup` bundles `uv sync` with a pre-warmed `uv tool install
kimi-cli` for Dockerfile / CI caches.

## Run

```bash
uv tool run visual-base gateway
```

Starts the recorder and Kimi chat channel together. Everything lives
under `$BUB_HOME` (default `~/.bub/`):

- **Video segments** — `~/.bub/eye/segments/eye_YYYYMMDD_HHMMSS.mp4`
- **Daily activity logs** — `~/.bub/eye/logs/YYYY-MM-DD.md`
