Skip to main content

Render any input as a portico – a three-layer ASCII visualization.

Project description

portico

PyPI Python HF Space

Try it onlineTry it locallyExampleInputsCustomization


About

portico renders input as a three-layered visual abstraction.

  1. An LLM reads your input, classifies it, and decomposes it into three layers _ii^: roof, pillars, base.
  2. The renderer turns those layers into a fixed ASCII shape that resembles a portico.
  3. It builds a tiny monument for the thing you're trying to understand.
Glyph Layer Meaning
^ Roof The unifying idea
ii Pillars The load-bearing components
_ Base The foundation everything rests on

Try it locally

Install

uv tool install portico-cli
portico README.md
portico https://example.com/article
portico ./src --no-legend
echo "your text here" | portico -

Try it online

Run portico in your browser, no install required:

–> Hugging Face Space <–

The space uses 🦙 Llama 3.3 70B via Groq. Paste input and render.

Example

portico "https://en.wikipedia.org/wiki/Transformer_(deep_learning_architecture)"
── encyclopedia article: Transformer ──────────────────────────────────────────

                                      ***
                                  ===  ◇  ===
     ╔═══════════════════════════════════════════════════════════════════╗
     ║                     Attention Is All You Need                     ║
     ╚═══════════════════════════════════════════════════════════════════╝
  ////º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º\\\\
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
       ▀██▀           ▀██▀           ▀██▀           ▀██▀           ▀██▀
        ██             ██             ██             ██             ██
        ██             ██             ██             ██             ██
   Predecessors   Architecture     Training      Efficiency    Applications
        ██             ██             ██             ██             ██
        ██             ██             ██             ██             ██
       ▄██▄           ▄██▄           ▄██▄           ▄██▄           ▄██▄
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
╔═════════════════════════════════════════════════════════════════════════════╗
║                        Scaled dot-product attention                         ║
╚═════════════════════════════════════════════════════════════════════════════╝

legend:
  ^  Attention Is All You Need: The 2017 thesis that pure attention, with neither
     recurrence nor convolution, suffices for sequence-to-sequence modeling —
     yielding parallel training and the foundational architecture of modern AI.
  ii Predecessors: RNN and LSTM seq2seq models suffered from vanishing gradients and
     sequential bottlenecks; Bahdanau and Luong attention bolted onto these
     recurrent backbones in 2014-15 set up the 2017 Vaswani et al. paper to drop
     recurrence entirely.
  ii Architecture: Tokenization, learned embeddings, and sinusoidal or learned
     positional encoding feed stacks of multi-head self- and cross-attention plus
     position-wise feedforward sublayers, composed into encoder-only, decoder-only,
     or full encoder-decoder variants with residual connections and layer
     normalization throughout.
  ii Training: Self-supervised pretraining on masked, autoregressive, or prefix-LM
     objectives followed by supervised fine-tuning, with Adam-family optimizers and
     warmup schedules, and pre- vs post-norm placement materially shaping
     convergence at depth.
  ii Efficiency: KV caching, FlashAttention's I/O-aware kernels, multi-query and
     grouped-query attention, speculative decoding, and sub-quadratic variants such
     as Linformer, Performer, and state-space hybrids cut the memory and compute
     costs of training and inference.
  ii Applications: Transformers underpin systems across NLP (BERT, GPT, T5), vision
     (ViT), speech (Whisper), code, multimodal generation (DALL-E, GPT-4o),
     structural biology (AlphaFold), robotics, and reinforcement learning.
  _  Scaled dot-product attention: The atomic operation that computes a softmax-
     weighted average of value vectors, with weights given by scaled query-key dot
     products — the single load-bearing mechanism from which multi-head, self-,
     masked, and cross-attention all derive.

──────────────────────────────────────────────────────────── built with _ii^ ──

Run with claude-sonnet-4-6.

Inputs

  • Raw text or stdin
  • Local files and directories
  • URLs (page content is extracted)
  • Git repositories

When an input doesn't fit a three-layer shape – poems, flat lists, gibberish – portico refuses honestly rather than fake one.

Customization

Flag What it does
--no-legend Hide the per-layer summary (legend renders by default)
--reapex=N Pin the apex to seed N (random by default; pool of 600+ variants)
--json Emit the analyzer's JSON instead of rendering
--diagnose Print a pipeline report (input type, model, fit quality) and exit

Run portico --help for the full list.

Apex

The apex is the ornament crowning the portico — picked at render time from a pool of 600+ variants.
🎲 --reapex=SEED pins a specific composition to reproduce.

portico https://0trm.blog/data-science-at-camp-nou/ --reapex=0
── essay: Data Science at Camp Nou ─────────────────

                       ▲ * ▲
                    ~~~  ▲  ~~~
     ╔════════════════════════════════════════╗
     ║         Data-Driven Ticketing          ║
     ╚════════════════════════════════════════╝
  ////º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~\\\\
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
        ▀██▀            ▀██▀            ▀██▀
         ██              ██              ██
         ██              ██              ██
     Analytics    Experimentation    Predictive
         ██              ██           Modeling
         ██              ██              ██
         ██              ██              ██
        ▄██▄            ▄██▄            ▄██▄
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
╔══════════════════════════════════════════════════╗
║                   Fan Behavior                   ║
╚══════════════════════════════════════════════════╝
portico https://0trm.blog/data-science-at-camp-nou/ --reapex=1
── essay: Data Science at Camp Nou ─────────────────

                        ◆ ◆
                    ═══  ◆  ═══
     ╔════════════════════════════════════════╗
     ║         Data-Driven Ticketing          ║
     ╚════════════════════════════════════════╝
  ////º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~\\\\
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
        ▀██▀            ▀██▀            ▀██▀
         ██              ██              ██
         ██              ██              ██
     Analytics    Experimentation    Predictive
         ██              ██           Modeling
         ██              ██              ██
         ██              ██              ██
        ▄██▄            ▄██▄            ▄██▄
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
╔══════════════════════════════════════════════════╗
║                   Fan Behavior                   ║
╚══════════════════════════════════════════════════╝
portico https://0trm.blog/data-science-at-camp-nou/ --reapex=7
── essay: Data Science at Camp Nou ─────────────────

                       · · ·
                    ░░░  ▲  ░░░
     ╔════════════════════════════════════════╗
     ║         Data-Driven Ticketing          ║
     ╚════════════════════════════════════════╝
  ////º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~~º~\\\\
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
        ▀██▀            ▀██▀            ▀██▀
         ██              ██              ██
         ██              ██              ██
     Analytics    Experimentation    Predictive
         ██              ██           Modeling
         ██              ██              ██
         ██              ██              ██
        ▄██▄            ▄██▄            ▄██▄
   ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
╔══════════════════════════════════════════════════╗
║                   Fan Behavior                   ║
╚══════════════════════════════════════════════════╝

License

MIT


Built by with AI.


© 2026 trm

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

portico_cli-0.1.4.tar.gz (24.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

portico_cli-0.1.4-py3-none-any.whl (32.2 kB view details)

Uploaded Python 3

File details

Details for the file portico_cli-0.1.4.tar.gz.

File metadata

  • Download URL: portico_cli-0.1.4.tar.gz
  • Upload date:
  • Size: 24.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for portico_cli-0.1.4.tar.gz
Algorithm Hash digest
SHA256 0333bfe1b0bbf5a28114599c93ee48aa0711f0c65b438be2eadce01a7814ec50
MD5 6419fc6ffcdc811b9cd99899a7301ef5
BLAKE2b-256 bd1c8ed6821b157ae64829359aa68105a0810990e8b1b5b4315d06136fcb170d

See more details on using hashes here.

File details

Details for the file portico_cli-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: portico_cli-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 32.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for portico_cli-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 b2b13b8302523c29414aef996404f85804a19e5753e414b36f7e6b6eaf7fe93f
MD5 deabe8ef1870a951583b8533733e8d78
BLAKE2b-256 7c48fda50875d710f6fe84f529861cf5a12965aa884250e6264b8960e4fb03b2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page