Use Lookout
Context and compaction
What the agent sees in a chat, how to add files and images to it, and how Lookout keeps long chats within the model's context.
The agent sees the chat so far, what you mention or attach, and what its own tools read. A chat also starts with your project's rules files, your memory (while Use memory is on, in Settings › Memory or the project's own settings), the skills the agent can use, and a few facts about the workspace: its folders, whether it's a git repository, your system and today's date. When the day changes in a long chat, the agent is told the new date in one line. A chat you come back to after its prompt cache expired, or one that has kept working for a day, runs on the current version's instructions, not the ones it started with.
Mention files, chats and more
Type @ in the message box and pick from the list, or keep typing to search it. ↑ and ↓ move, ⏎ inserts, Esc closes. The list groups Recent, Agents, Files, Chats, Projects and Skills. Each agent shows its section after its name, the chat's own team first, so agents with the same role in different sections are told apart; typing a section's name, or a part of its path, lists its agents.
| Mention | What the agent gets |
|---|---|
| A file | Its text, up to 20,000 characters, and where to read the rest |
| A folder | A list of what's in it |
| A chat | Its title and state, where to read its history, and how to send it a message |
| A project | Its folders, and where to read its chats |
| A skill | The skill's instructions |
| An agent | Who that agent is, in an agent's chat in the Mac app |
You can also type a path after @, such as @src/app.ts, and send it as it is: it attaches like a picked file.
A skill has a second way in: / and its name anywhere in the message, as in "then use /review", lists your skills,
and the one you pick becomes the same mention (Use a skill).
Attach images and files
Paste them, drop them anywhere on the chat or the new chat page, or click + and choose Image or File. While you hold a file over the page it shows where the file goes. Click an attachment to preview it. To remove an image, point at it and click the × on its corner; a file's × always shows.
An attachment alone is a whole message: send a screenshot with no words, and the agent works from the image.
Read the context meter
Once a chat fills a tenth of its model's context budget, a ring appears at the end of the line under the message box, alone. Hover it for the percentage, how many tokens the chat holds and where it will be summarized. Close to the summary point the ring turns amber and says how full it is, such as 90% full; the same place says when the chat's plan needs you.
Click the ring for its card: under This chat, tokens used out of the model's budget and Compact now; under Plan, the plan the chat's model runs on.
What fills it names the part that takes the most of the chat's context and its share, and the two largest when they fit. Click it for every part, in tokens, together the size Lookout estimates for the next request:
Under the parts, Last response's prompt is the size the provider counted for the agent's latest reply, split as the Usage tab splits tokens: Input (sent uncached), Cache write and Cache read. The estimate and that count differ by what the chat gained since the reply, and by how closely the chat's replies have taught Lookout the model's tokens.
Under that, Cache shows the share of the chat's prompt tokens read from the provider's cache, then its requests' tokens so far split the same way: Input (sent uncached), Cache write (where the provider reports it), Cache read, Output, and their Total. Where the price is known it adds the cost: Cost so far on an API key billed per token, At API prices on a subscription (what the same requests would cost billed per token). Warm cache says how long the cache stays warm if you send nothing, or Expired once your next message has to send the whole chat again. When the chat's rules run past their budget, Rules names each file that was cut and the line its rest starts at; click one to open it there.
The message box's send button says what ⏎ does. When the last turn stopped before it finished, an empty message box's send runs the stop's main action and draws it: a circling arrow for Retry or Retry now, a clock for Wait for the reset, the send arrow for Continue on another model, which its name says. Hover it for the action's name, the same words as the stop's own button. While the agent works, the line under the message box says what a message does, Queue or Steer, and the key that sends it the other way; the send button's tooltip names it.
How compaction works
When a chat nears its model's summary point, Lookout makes room before the next request. Each model's point follows where its maker's own coding agent compacts it, close to the end of the window on most 1M models; a model with no such guidance uses 85% of its budget. The context meter shows the model's whole window, with a mark at the summary point; its hover names both.
The agent keeps your current request word for word, your earlier messages word for word as far as they fit, every skill you attached to an earlier message as it was attached, a summary of the work done since, and its most recent steps with their output as the agent read it (cleared again only if the chat still wouldn't fit). Output the agent hasn't read yet is never summarized. When it can't fit whole, the agent gets its beginning and its end, with which lines were left out and the file holding all of it, before anything else happens to it. A request that still wouldn't fit the model's window is never sent: the turn ends with Context window exceeded.
The tool calls of one step share about a third of the budget between them. A result past its share keeps its beginning and its end, and the rest is saved to a file the agent can read with the line numbers it names, so one step of many large reads can't fill the window.
Every request sends every image the chat still holds. Where a model's provider gets slow or refuses past a size, Lookout keeps a budget of image bytes per request: once a request would carry more, it clears the oldest images the agent has already seen until the request carries half the budget. Each cleared image leaves a line in its place with its name, size and the file that shows it again, which the agent reads when it needs the image back. The images in your current request, in the agent's latest step, and the five most recent stay, unless a request would still carry more images than the provider takes at all (12 MB for ChatGPT, 24 MB for Claude): then those clear too, oldest first, so the newest always goes. Images count toward the context by their size, as each model's maker counts them.
Each compaction row shows the tokens before and after. Open it to read the summary and see which files the agent read again. Lookout keeps the chat's full context from before the summary in a file, and the agent can search it when it needs a detail the summary left out. Open original context shows that file in Finder; in a browser, Copy original context path copies its path.
Switching a chat to a model with a smaller context compacts it if it no longer fits. A summary written while the chat sat idle is used as it is; otherwise the model you left writes the summary while it still holds the chat in its cache, and if it can't, the new model writes it, taking the time it needs. Stop ends the wait and keeps what was cleared so far.
Long chats left idle
A provider keeps a chat cached for a while after each reply, and reading it from there costs a fraction of sending it again. When a chat of 100K tokens or more goes quiet, Lookout can use that time, set in Settings › Chat › Advanced › Before the cache runs out:
Keep the cache warm (on by default) goes further where the provider offers it: shortly before the cache runs out, a short request reads the quiet chat from the cache so it stays cached as it is, for as long as that costs less than sending the chat again, and then the summary takes over. The same keeps a chat and its subagents cached while a long command runs. Each one shows on the Usage tab as Cache kept warm.
Some providers' caches also run out for every chat at one time of day, however recently it was read. Lookout plans for that: the summary is written a few minutes before, nothing is sent to keep a chat warm across it, and a chat you come back to after it starts from that summary.
The summary runs only on providers whose cache prices make it pay, never for an archived chat, while the agent or one of its subagents works or when the model's plan is nearly spent. While you type in the chat it waits until a minute after your last keystroke. With several accounts of one provider, the summary and the requests that keep the cache warm go only to the account holding the chat's cache, and only while your next message would go there too, and the chat stays on that account when you come back. Its cost shows on the Usage tab.
Compact by hand
Between turns, any of these summarizes the chat now:
To say what the summary must keep, type it after the command: /compact keep the migration plan. The summary keeps
what you name in full detail. The words are an instruction for the summary only: they start no turn, and the agent
never gets them as a message.
Compacting by hand isn't available while the agent works: a /compact sent then stays in the message box, and Lookout says Compact once the turn ends. If there's nothing to summarize, Lookout says Nothing to compact.
When the context runs out
If a task's working set can't fit even after compaction, the agent stops using tools and replies with what's done, where things stand and what remains. The turn ends with Context full. Send a follow-up with a narrower request to continue.