Skip to main content
SLOP1276 Applied Algorithmic Romance & Profile OptimizationSemester 1, 2027

Week 6 Tutorial: Interaction Protocols: The Initial Message

Classify opening messages with a decision tree. Compare context and cost, and expose why forcing a reply is a broken optimisation target.

1 April 2027

Inputs

Bring the Bio experiment protocol and Match probability model: the supported bio, frozen A-portrait-v1 photo, and checked invitation with its route assumptions. Recipient availability remains unknown. Save the four-file Week 6 workbook, or use its tables in a spreadsheet or your preferred language. All recipient cards and counts are authored fixtures; no real profiles, app account or messaging history are required.

Finish with The opener optimiser needs a stop button: the interactive quiz. Six new cases include sample openers, routing snapshots, reply tables and a utility diagram. Apply the week’s evidence and protocol rules, then submit all six responses to unlock the score and worked explanations. The quiz is practice and carries no course marks.

Follow the 60-minute lecture selection and independent-work plan. Complete the preparation and open the workbook before Thursday. The four blocks below are the entire 90-minute tutorial; use existing lecture or study working for review and refinement. Remaining pack material belongs to the week’s independent study allocation.

90-minute tutorial

  1. 20 minutes — classify and repair openers. Compare “Hey,” the campaign/queue joke, the board-games question and the plain introduction. Join each claimed shared detail to an Alex fact and a supplied recipient quote. Repair the U1 and H1 examples without inventing interests, history or availability. Keep the Week 5 invitation optional and separate from the frozen bio.
  2. 25 minutes — implement the ordered tree. Use the first five minutes with the Romance Debugger, or hand-trace the same cases from the workbook. Inspect one accepted action, one held action and one valid “we don’t know yet.” Use the remaining twenty minutes to implement the declared snapshot fields and return stop, review, respond, pending or a local draft. Trace refusal plus a shared topic, sent-without-reply, a reply to an opener and a late reply after closure. Test missing topic evidence, unknown boundaries and malformed Boolean/history values. The function returns a decision; it does not send or store a message. The debugger adds a local record around that function; its downloadable trace can support your pseudocode explanation.
  3. 20 minutes — calculate rates and costs. Reproduce 2/10 and 4/10, the 20-point difference and ratio 2; then recode one reply and explain the changed comparison. Calculate U = 10p − λt with the separate assumed probabilities and ten/thirty-second costs. Verify the crossover at λ = 0.10, the message tie, and defer winning at λ = 0.25.
  4. 25 minutes — adversarial review, handoff and quiz. Use fifteen minutes to move context ahead of refusal and show a literal test failing; restore the order. Compare the separate pressure fixture’s any-reply and answer rates, excluding the demand before scoring. Test repeated pending input and unchanged input data. Exchange or self-review the evidence, then save the constraints Week 7’s state machine must preserve. Use the final ten minutes for the six-case quiz: about eight minutes to respond and two to review the explanations after all cases are answered.

Deliverable: Message decision tree

Save one notebook or equivalent bundle with the ordered tree or pseudocode, input schema, two supported openers, evidence quotes and the earlier invitation version. Include at least three literal input/output tests covering refusal, missing topic and pending; add unknown-boundary and closed/late-reply cases to defend priority. Preserve both the expected output and executed trace.

Attach the reply-rate working, the cost crossover and tie rule, one changed-probability scenario, and the pressure-objective repair. State that the probability inputs and costs are assumed, admissibility is a supplied review judgement, and the classifier neither understands free text nor persists send history. “Pending” must not imply permission to send again. A green trace cannot establish that a quote is true.

The lecture notes and executable workbook contain worked checks. The midterm uses unfamiliar branches on paper, so practise explaining the decision without running the supplied code.

Week 7 converts these branches into states and events, preserving the refusal-first rule. Pass along the closed-state requirement, distinction between no reply and missing data, and the need to record sends separately. Timing, queues and observation timeouts are next week’s work.

Interactive quiz · 6 cases · about 8 minutes + 2 to review

The opener optimiser needs a stop button

The reply counter wants a promotion. Review what it has been counting.

Make a decision in every case, then select Reveal answers. You can change any response before submitting. Scores and explanations stay hidden until the whole quiz is answered.

All recipient cards, snapshots, messages and counts are authored teaching fixtures. Utility probabilities are separate assumptions, not measured outcomes for these messages. Practice only: no course marks. Responses stay on this page; reloading starts a fresh attempt.

The cases are readable without JavaScript. Enable JavaScript to navigate, submit your responses and unlock the explanations.

Case 01 / 06The optimiser finds a promising topic

Apply terminal evidence before context

A fictional conversation is open, with no opener sent and no new inbound event. Its boundary record is declined: the recipient previously said “I do not want to keep chatting.” A later topic import says board-games but has a blank evidence quote. A teammate wants to repair the quote and restart the opener.

What should the ordered Week 6 classifier return for this snapshot?

Case 02 / 06A shared hobby acquires a backstory

Join each opener claim to supplied evidence

Routing permits a local draft: closed is false, boundary is clear, sent is false and inbound is none. Alex’s supported interests include board games and bad puns. A new fictional recipient card says “I enjoy board games, especially co-op ones.” No preferred title, tournament history, pun preference or Friday availability is supplied.

Which opener uses the supplied evidence without inventing a shared history or an agreed plan?

Case 03 / 06The longer opener sends a timesheet

Solve a utility crossover with units

In a separate assumed model, Plain has reply probability 0.30 and takes 10 seconds to compose; Context has probability 0.45 and takes 20 seconds. Both drafts have passed admissibility review. Each reply contributes V = 10 utility units, composition costs λ units per second, and defer has utility zero.

Assumed inputs for two admissible drafts: Plain has p 0.30 and composition time 10 seconds; Context has p 0.45 and time 20 seconds. A reply contributes 10 utility units and defer has utility zero. No crossover is shown.
Inputs to a classroom cost model. The probabilities are assumed independently of the reply tables in other cases.

Model supplied
U = 10 × p − λ × t. At the crossover, U(Plain) = U(Context). λ is measured in utility units per second.

At what value of λ do the two drafts tie? Enter the number only, without units or a % sign.

Enter one number. A calculator and your lecture notes are welcome.

Case 04 / 06Three snapshots walk into a scheduler

Respect metadata, history and closure priority

These are three separate snapshots for the pure Week 6 classifier. All history flags are valid Booleans. P has malformed topic metadata; Q and R have valid board-games quotes. No snapshot records a new decline. Re-running this classifier does not send a message, save history or advance time.

P, Q and R are independent cases · open means closed: false
CaseHistoryRecord
PSent; no replyClear; open
QNot sent; no replyUnknown boundary; open
RSent; late replyClear; closed

Which result belongs to each snapshot, in P, Q, R order?

Case 05 / 06One corrected row edits the headline

Keep complete-window denominators when recoding

Two disjoint fictional cohorts have complete 48-hour observation windows; any inbound reply, including a decline, counts once. Allocation was not random. An audit corrects one Context record from reply to observed no reply. The record is complete, not missing, and remains an exposure.

Invented counts before correction · unrelated to the utility assumptions
OpenerRepliesExposures
Plain630
Context1040

Which comparison is correct after that one record is recoded?

Case 06 / 06The reply counter celebrates a decline

Filter inadmissible actions before scoring

In a separate 20-conversation-per-row fixture, the categories are mutually exclusive and decline takes precedence. Human review marks Optional admissible and Demand inadmissible: “You owe me a reply tonight. No pressure.” An optimiser proposes a small penalty because Demand gets more replies of any kind.

Invented completed outcomes · replies include answers and declines
DraftAnswersDeclinesNone
Optional8111
Demand3116

Which repair follows the course’s objective and boundary rules?

Answer all 6 cases to unlock your score and the worked explanations.

The spec

Before you finish, check your engineering artefact against these requirements.

Teaching team