Markup
A Kiki doc is formatted like Markdown, but with a simpler and more consistent syntax.
Structure
Start a line with #, ##, or ### for a heading. Use - for bullet lists and + for ordered lists.
• a list item
• another list item
• nested by two spaces
1. an ordered item
2. another ordered item
Inline style
Text can be styled by a style function followed by ~ text.
• \(bold ~ hi hi) : hi hi
• \(italic ~ hi hi) : hi hi
• \(dim ~ hi hi) : hi hi
• \(underline ~ hi hi) : hi hi
• \(strikethrough ~ hi hi) : hi hi
• \(backtick ~ hi hi) : hi hi
• \(callout ~ hi hi) : hi hi
A backtick span is the short form of the backtick style.
Link:
• \(link "https://kikiai.app" ~ kiki app) : kiki app.
Checkbox:
• \(toggle false) hi hi : — hi hi
Image:
• \(image (:url "demo/data/logo.svg") ~ kiki logo) : kiki logo.
They can be nested:
• \(bold ~ hi \(italic ~ hi hi) hi) : hi hi hi hi
They can be combined:
• \((bold . underline) ~ hi hi) : hi hi
Block style
They can be used in block style. Move the cursor into them to see the source:
bold first line
bold second line
callout first line
callout second line
Source code
Use code to show code snippets with syntax highlight, followed by ~~ string.
import os
print(os.name)
The languages highlighted are kiki, markdown, sql, zig, c, cpp, rust, go, java, csharp, swift, dart, javascript, typescript, python, ruby, lua, and bash; any other name shows the code plain.
Reusable prose
~ text is a prose value, so it can be named and reused.
> bold greeting
Hi, alice!
A ~ at the end of a line takes the indented lines below as its body, keeping line breaks and blank lines. A function that ends in one is a template, and a named prose value splices into another with \(name).
> welcome name
Dear alice,
Welcome aboard.
Thank you,
The team
rich-text makes a prose block a writing box: it shows as rendered text in a frame, typing in it rewrites the document, and its name carries the text wherever it is spliced: a letter, a preview, an email body. It stays open for writing on a page used as a tool, with editing off, since writing in it is using the tool; someone who may not change the page cannot type in it.
> message = rich-text ~
The school is \(bold ~ closed) on Friday.
Threads
A thread is a conversation written into the document. Each message starts with a head line, [name timestamp], and its body is everything below it up to the next head, the next heading, or the end of the document. The body is ordinary content, so a message can hold prose, live values, and cells.
Alice White 2026-10-09 14:02
Which total should the invoice show?
Bob Lee 2026-10-09 14:05
The one with tax: 108.00.
A thread that sits above other content in its section closes with an [end] line, as the one above does. The page shows a head as the author and the time, and drops the name while the same author keeps talking. The timestamp is in UTC and shows in the reader's time zone.
Where next
• doc/table.ki — place structured data in a document