How AMP Works
Understanding the adaptive motivation learning loop.
The Core Problem
Different users are motivated by different things. Some want step-by-step guidance, others prefer to figure things out themselves. Some respond to achievement-focused language, others to learning-focused language.
Traditional AI agents use the same communication style for everyone, leading to:
- Lower task completion rates
- Frustrated users who don't connect with your agent's style
- Wasted engineering time building personalisation logic
The AMP Solution
AMP automatically learns what motivates each user and provides real-time context to adapt your agent's behaviour.
The Learning Loop
- 1Request Context
Your agent calls
getContext()with the user ID and task description. - 2Receive Recommendations
AMP returns motivation-aware context: communication style, framing approach, complexity handling.
- 3Adapt Response
Your agent uses the context to personalise its response to the user.
- 4Report Outcome
After the interaction, you report whether the user started, completed, or abandoned the task.
- 5Learn & Improve
AMP updates the user's motivation profile, improving future recommendations.
Example Flow
Let's walk through a real example of AMP in action:
1. User Makes a Request
A user asks your coding agent: "Help me build a login page"
2. Agent Requests Context
const context = await amp.getContext({
userId: "user_123",
task: "build a login page",
complexity: "medium",
});3. AMP Returns Context
Based on the user's historical behaviour, AMP returns:
{
"requestId": "req_abc123",
"suggestedFraming": "micro_task",
"communicationStyle": "brief_directive",
"complexity": "break_into_steps",
"rationale": "User has 85% completion rate with step-by-step guidance",
"confidence": 0.87
}4. Agent Adapts Its Response
Your agent uses this context to structure its response:
// Build a system prompt using AMP's recommendations
const systemPrompt = `You are a coding assistant.
Communication: Brief and directive (no fluff).
Task framing: Break this into micro-tasks.
Approach: Give step-by-step guidance.`;
// Generate response
const response = await openai.chat.completions.create({
model: "gpt-4",
messages: [
{ role: "system", content: systemPrompt },
{ role: "user", content: "Build a login page" },
],
});5. User Completes the Task
The user follows the steps and successfully builds the login page. Your agent reports this success:
await amp.reportOutcome({
requestId: context.requestId,
started: true,
completed: true,
timeToStart: 30, // seconds
flowState: true, // user seemed engaged
satisfaction: 0.9, // optional feedback score
});6. AMP Learns
AMP updates the user's profile:
- Reinforces that this user responds well to step-by-step guidance
- Notes they prefer brief, directive communication
- Increases confidence in "micro_task" framing for this user
Motivation Dimensions
AMP analyses user behaviour across multiple dimensions:
Task Framing
How should the task be presented?
- • Achievement: "Complete this feature"
- • Learning: "Explore this concept"
- • Micro-task: "Do step 1 first"
- • Challenge: "Can you solve this?"
Communication Style
How should information be delivered?
- • Brief Directive: Concise instructions
- • Detailed Explanatory: With context
- • Conversational: Friendly tone
- • Technical: Precise terminology
Complexity Handling
How much hand-holding?
- • Full Solution: Complete answer
- • Break Into Steps: Guided process
- • Hints Only: Clues to solve it
- • High Level: Conceptual overview
Encouragement Level
How much positive reinforcement?
- • High: Frequent encouragement
- • Moderate: Balanced feedback
- • Minimal: Results-focused
- • None: Pure technical exchange
The Machine Learning Model
AMP uses a multi-armed bandit approach combined with collaborative filtering:
Initial Phase (Cold Start)
- New users start with population-level defaults
- AMP tries different approaches to gather data
- Learns from similar user patterns (collaborative filtering)
Learning Phase
- Builds individual motivation profile from outcomes
- Increases confidence in effective approaches
- Reduces exploration, increases exploitation
Optimised Phase
- High-confidence recommendations based on proven patterns
- Continues to adapt as user behaviour evolves
- Detects and responds to context shifts
💡 Key Insight: AMP doesn't just classify users into rigid types. It builds a dynamic, multi-dimensional profile that evolves with each interaction.
Privacy & Data
AMP is designed with privacy in mind:
- Only behavioural patterns are stored, not task content
- User IDs are hashed and anonymised
- No PII (personally identifiable information) is required
- Data is encrypted at rest and in transit
- Full GDPR and CCPA compliance