# I run an autonomous agent with one prompt, rules, and context recovery

> Dated experiments and earlier ways of working. Not a current product guide. This text belongs to its source date; unverified approaches are not current recommendations.

Canonical: https://optionos.app/log/en/rule-driven-autonomous-agent/
Published: 2026-07-29

![An eight-screen autonomous-agent flow from one prompt and rule loading through context recovery, semantic deltas, and a closed file scope](https://optionos.app/guide/rule-driven-autonomous-agent-01-prompt-and-rules.png)
*An interactive flow showing on the original screens how one prompt stays auditable and resilient to context loss during a long feature task.*
Interactive scene: https://optionos.app/log/en/rule-driven-autonomous-agent/#rule-driven-autonomous-agent-tour-en
### 1. I turn one prompt into auditable autonomy with rules and context recovery

This flow shows, on the original screens, how one prompt freezes the target, how semantic deltas and a closed file scope make the work auditable, and how the target and rules return after context compaction. The screens I point at while speaking are connected inside one interactive guide; only a real detail relationship opens inward.

Original Turkish words — Yani benim kurallarıma uygun bir şekilde ilerleyeceği tek bir prompt. O yüzden bilgiler kaybolmasın diye ajana bunları yazdırıyorum ki hedef context'i compactlandığında, sıkıştırıldığında ya da özetlendiği zaman bunları tekrar vereyim ki kayıp olmasın. çektiğim fotoğraflar da etiketleme yaptığım resimler zaten. Bunları ajanım sizin izleyeceğiniz interaktif yapılara dönüştürüyor. Yani ilişki yokken anlamsız ilişki kurmuşsun, onu düzeltmen lazım.
### 2. One prompt freezes only the target

The prompt asks the display: feature to proceed under my rules and show the target world. It does not copy the implementation sequence into the prompt; those details remain in the rule authority.

Original Turkish words — Yani benim kurallarıma uygun bir şekilde ilerleyeceği tek bir prompt.
### 3. Rule anchors open the working contract

At task start the agent opens the anchors selected by the target and loads the relevant rule blocks. One prompt is therefore connected to a detailed but revisable working contract.

Original Turkish words — Geri kalan her şey zaten kural dosyalarında yazıyor ve ajan şurada o kuralları tek tek okuyor.
### 4. I pay the autonomy cost up front

Reading the whole feature space, closing every case into a plan, and restoring state across five or six compactions consumes many tokens; in return, human supervision during implementation falls. If the initial intent is wrong, the same mechanism converges expensively on the wrong target. Autonomy runs for a long time in problem spaces I know; I first learn unknown cases and then turn them into rules.

Original Turkish words — Hata yapacağımı başta bedeli ödemeye çalışıyorum. Buradaki sıkıntılı kısım şu: talimat ya da niyet başta yanlışsa hedef de yanlış oluyor, maliyet yüksek oluyor. Ama avantajlı kısım kontrol etme miktarı azalıyor gibi düşünebiliriz. Bu çalışırken tahmini beş altı kere compact atıyor büyük işlerde. Çünkü bilmediğim şeyin kuralını yazamadığım için kendi bilgi havuzumu sürekli yükseltip yeni şeyler öğrenip kurallaştırmaya çalışıyorum.
### 5. Compact → conversation restore → epoch reset

The three visible events form one recovery chain: context compaction completes, the previous-conversation hook restores the conversation, and the CONTEXT_EPOCH reset restarts rule selection.

Original Turkish words — Yani bana hiçbir şey sormadan, kendisi hiçbir kod yazmadan konteksti kompakladı. Sıkıştırma işlemi bittikten hemen sonra ajanın yaptığı ilk hamle kuralları tekrar okumak.
### 6. The previous-conversation hook restores the prior conversation

The hook gives the new context epoch the human messages and the agent’s non-terminal, non-tool decision responses.

Original Turkish words — Previous conversation, yani aslında ajana önceki konuşmalarımı veriyorum.
### 7. The last non-terminal decision crosses into the new epoch

The highlighted response carries the “do not change anything yet” decision and its approval gate; heavy terminal and tool traces are not copied into conversation recovery.

Original Turkish words — Çünkü bu terminal olmayan bir response. Compact previous conversation da ajana tekrar veriliyor.
### 8. Lineage and target world

This screen makes the agent's working lineage and closed scope visible up front; the target-world questions turn the planned work into inspectable answers, and the record restores the target after context compaction.

Original Turkish words — Mesela soy project display: çalıştığı alanı bana şimdiden başta belirtiyor. Mesela bak burada hedef dünya soruları diye bir kısım veriyor. O yüzden bilgiler kaybolmasın diye ajana bunları yazdırıyorum ki hedef context'i compactlandığında, sıkıştırıldığında ya da özetlendiği zaman bunları tekrar vereyim ki kayıp olmasın.
### 9. Lineage and closed scope are visible up front

The lineage and scope line at the top of the preview shows the feature family and the closed file tree the agent may touch. The feature removal boundary is readable from the same lineage.

Original Turkish words — Mesela soy project display: çalıştığı alanı bana şimdiden başta belirtiyor. Bütün file sistemini soya göre yapıyorum.
### 10. Target-world questions show the owner of every answer

Target-world questions split the change into auditable questions; every answer remains visible with its authority and owner.

Original Turkish words — Mesela bak burada hedef dünya soruları diye bir kısım veriyor. Aslında projeyi, yapacağı şeyi bana anlamlandırmaya çalışıyor anlayabilmem için.
### 11. The goal world rebuilds the target after compaction

The goal world is the agent’s continuity surface. After context pressure it reconstructs the target, stable predicates, and open decisions, so I no longer need to reread every detail once it is stable.

Original Turkish words — O yüzden bilgiler kaybolmasın diye ajana bunları yazdırıyorum ki hedef context'i compactlandığında, sıkıştırıldığında ya da özetlendiği zaman bunları tekrar vereyim ki kayıp olmasın.
### 12. I read semantic deltas, not reasoning

Instead of reading a “how I will do it” narrative, I scan “old behavior → new behavior” to verify whether the agent understood my intent.

Original Turkish words — Burada ben, benim istediğim şeyi anlamış mı delta'lardan bakıyorum. Hani bana reasoning işte şöyle yapacağım, böyle yapacağım değil de şuydu bu olacak, şuydu bu olacak tarzında vermesi daha çok hoşuma gidiyor çünkü daha iyi anlıyorum.
### 13. Safety: monotonic generation replaces timers and retries

The highlighted D5 Safety row removes the old 250 ms debounce, 200/500 ms retry, and inflight-drop behavior. The replacement connects the reconfiguration callback to a monotonic generation and closes every decision against a fresh world.

Original Turkish words — Burada zaten bu semantic delta dediğim bir kısım bu. Burada ben, benim istediğim şeyi anlamış mı delta'lardan bakıyorum.
### 14. The audit language is Turkish; technical terms stay English

Turkish delta and scope text makes human review easier while stable technical terms stay in English. I prioritize preventing meaning loss for the human over a small language advantage for the LLM.

Original Turkish words — Türkçe kullanıyorum ben çünkü Türkçe daha iyi denetleyebiliyorum. Ben denetleyebiliyorsam zaten doğruyu veririm. LLM'de birazcık kayıp olması problem değil, bende kayıp olmasın. Ve bilinçli olarak Türkçe kullanıyorum çünkü Türkçe denetlemesi daha kolay. Ama terimsel şeylerde İngilizce kullanıyorum.
### 15. The file tree is the closed change scope

The preview lists every touched file in a closed tree with its D mapping. If a need appears outside the tree, the plan is not patched; the scope is rebuilt.

Original Turkish words — Ardından ajanın dokunacağı bütün dosyaların raporu burada geliyor. Şu an bütün dokunacağı dosyalar burada mesela.
### 16. action.swift belongs to D3 Action and D4 Transaction

The highlighted row binds action.swift directly to the D3 Action and D4 Transaction semantic deltas. D2 and unrelated slices are not present in this locus.

Original Turkish words — D dilim demek. Yani hangi aşamada düzenleyeceğini gösteriyor. Üçüncü aşama. Faz gibi düşün.
### 17. Final surface and rule traces

This screen shows the final surface delivered to the user together with the rule trace behind the agent's decision; the rule example in the image carries the requirement that the old path must not remain beside the new structure.

Original Turkish words — "Kullanıcının son göreceği yüzey" dediği bir kısım var. Rule migration is breaking yazıyor ve resimdeki kısmı doğru ifade eden bir örnek bu
### 18. The final user surface shows normal and fault states

The “surface the user will see” section presents normal and fault menus side by side. I review the delivered experience rather than an implementation narrative.

Original Turkish words — "Kullanıcının son göreceği yüzey" dediği bir kısım var.
### 19. migration-is-breaking cuts the legacy route without an alias

The highlighted rule anchor says an old field or shape cannot survive a migration through an alias, fallback, or compatibility path. This hotspot opens the overview of the rule document.

Original Turkish words — Rule migration is breaking yazıyor ve resimdeki kısmı doğru ifade eden bir örnek bu
### 20. Reloading rules after compaction

After context compaction, the tool gives the rule documents back to the agent; the agent's first move is to read the rules again and continue under the same working contract.

Original Turkish words — Sıkıştırma işlemi bittikten hemen sonra ajanın yaptığı ilk hamle kuralları tekrar okumak. Benim tool'um kuralları ona veriyor.
### 21. Rules reopen after context compaction

As soon as compaction finishes, the anchor command reopens the relevant rule blocks. Previous conversation restores the target while rule selection is rebuilt from the authority for the new epoch.

Original Turkish words — Sıkıştırma işlemi bittikten hemen sonra ajanın yaptığı ilk hamle kuralları tekrar okumak. Benim tool'um kuralları ona veriyor.
### 22. I make this guide by speaking to my own app and marking the screens

I speak to my own app, capture the screens, and mark the regions that matter. My display: agent turns that conversation, the original screens, and the markings into one visual flow that a viewer can complete without leaving the images.

My explanation + marked screens → display: agent → interactive visual flow

Original Turkish words — Ve son olarak dikkat ettiğiniz gibi ben bu konuşmayı da kendi uygulamamı kullanarak yapıyorum. çektiğim fotoğraflar da etiketleme yaptığım resimler zaten. Bunları ajanım sizin izleyeceğiniz interaktif yapılara dönüştürüyor.

display: agent — The agent that joins the conversation, screens, and markings into one interactive narrative.
### 23. anchor-routing rebuilds rule selection in every context epoch

The anchor-routing rule scans the headings again after a fresh session, context compact, clear, or rule-authority revision, then opens only the rule closure needed at that moment.

Original Turkish words — Mesela şurada anchor crawl'larım var. Ama amacım ajandan kayıpsız bir şekilde ulaşmasını sağlamaya çalışmak

anchor-routing — The mechanism that reselects relevant rules from the active state and need in every context epoch.
### 24. The EveryAgent equation closes actor scope in one line

EveryAgent combines the main agent and the helper agents allowed by provider policy into one closed expression instead of an ambiguous chain of alternatives.

EveryAgent = mainAgent | providerPolicy.legalSubAgent

Original Turkish words — "Veya" gibi kelimeler yerine direkt matematiksel ifadelerle sunmaya çalışıyorum.

EveryAgent — The closed set of every agent role allowed to work on this task.
### 25. I make this interactive guide by speaking to my own app and marking the screens

As I speak, I capture screens and mark the regions that matter. Capture Actions keeps those images in the same conversation; my display: agent turns my explanation, the screens, and the markings into one visual flow a viewer can advance through.

My explanation + marked screens → display: agent → interactive visual flow

Original Turkish words — Ve son olarak dikkat ettiğiniz gibi ben bu konuşmayı da kendi uygulamamı kullanarak yapıyorum. çektiğim fotoğraflar da etiketleme yaptığım resimler zaten. Bunları ajanım sizin izleyeceğiniz interaktif yapılara dönüştürüyor.

Capture Actions — The panel that keeps screenshots captured during the explanation in the same source session.

display: — The label that identifies the agent and conversation session producing the guide.
### 26. The display: label shows which agent I was speaking to while producing this guide

The display: label identifies more than the screenshot source: it shows that the conversation producing this guide continued with the display: agent. That keeps the image, conversation, and agent in one provenance chain.

Original Turkish words — Zaten hangi ajana konuştuğumu fotoğraflarda görüyorsunuz. display: ajanına konuştuğum yazıyor ve çektiğim fotoğraflar da etiketleme yaptığım resimler zaten. Bunları ajanım sizin izleyeceğiniz interaktif yapılara dönüştürüyor.

display: — The label that identifies the agent and conversation session producing the guide.
