CourseModel Context Protocol · Module 4: Resources, Prompts and Interaction · part 27 of 83
Part 27 · Module 4: Resources, Prompts and Interaction

Topic 6: Module 4 milestone and interview questions

8 min read·22 Sept 2026

Project Milestone

After this module, your working copy of notes-assistant contains:

text
notes-assistant/
  notes/                              8 sample notes (unchanged)
  notes_assistant/                    store.py, llm.py, host.py, ... (unchanged, imported)
  examples/
    m04_server.py                     search_notes, create_note, notes://index, notes://{note_id}, summarise_topic
    m04_interaction_server.py         confirming create_note (form mode), import_zotero (URL mode), /connect page
    m04_resources.py                  list, templates, read, hostile URIs
    m04_uri_layers.py                 which defence layer stops which URI
    m04_context_cost.py               context cost of resources versus tools
    m04_subscribe.py                  subscriptions/listen with a writer and a file watcher
    m04_listen_raw.sh                 raw listen stream with curl
    m04_create_over_http.py           helper for the raw listen demo
    m04_prompt_wire.py                prompts/list and prompts/get as JSON
    m04_slash.py                      slash-command host
    m04_elicit_client.py              elicitation_callback for both modes
    m04_mrtr_raw.sh                   raw InputRequiredResult with curl
    m04_mrtr_manual.py                manual MRTR loop, resume, tampering
    m04_round_cost.py                 timing one versus two rounds
    m04_no_callback.py                the missing-callback failure
    m04_secret_in_form.py             the anti-pattern, on purpose
    m04_hitl.py                       host gate plus server gate
    m04_sampling_roots.py             deprecated features and replacements
    m04_legacy.py                     same code on 2025-11-25
    m04_lab.py                        the module lab
  tests/
    test_m04_interaction.py           9 tests

Code explained

  • In simple words: the map of what you built in this module and where it lives.
  • What happens: the canonical package in notes_assistant/ is untouched and imported everywhere. Everything new is a prototype in examples/ plus one test file.
  • Comes out: the server design has converged on the capstone's: tools search_notes and create_note, resource notes://index, template notes://{note_id}, prompt summarise_topic. Module 5 turns m04_server.py into the canonical notes_assistant/server.py, with configuration from the environment and tests. The interaction features (confirmation, URL mode) stay as optional extensions; the capstone's approval step lives in the host.

The rest of this course is yours to keep

This course is bought on its own, once, and stays readable afterwards, including the parts added to it later.