I posted last year about using AI to help me learn. I had read a paper that suggested how ChatGPT could help with learning, based on a framework of self-directed learning, and tried it out by pasting a whole chunk of the paper into Claude. It worked really well, and since then I’ve been using the same framework to level up my skills and learn about new codebases.
Today I published it as a skill to share it with others and make it easier to work with from a CLI.
In this blog post I’ll explain more about it, and show you how to use it yourself.
The framework and my additions
The original framework by Lin (2003) described various steps relating to self-direccted learning, from setting goals, to selecting activities, and assessing strategies - see my previous post for more details on this. I extended it specifically for practices I find useful when learning a new codebase, via trial and error:
- timeboxing the activities to a particular length to make them predictable and avoid falling into a rabbit hole
- saving notes to refer back to later, with specific sections for human-generated content vs. AI-generated content
- using checkpoint questions where the agent asks me questions before we move on, to make sure I have good understanding
- having the agent create visual diagrams via ASCII drawings of code flow to use as a reference when learning the structure of the code
- using the Socratic method - the agent asks questions, I answer, and the agent patiently guides through any mistakes
- the agents asks me to guess what a particular piece of code doe, and then we verify what was correct/incorrect
A concrete example
The problem
Here’s a concrete example of where I’ve used this. I was working on ellmer, an R package for working with LLMs directly from R. The particular problem I was trying to solve required me to understand some internals of ellmer I’d not worked with before - how tool calls work.
To really understand this properly, I needed to trace the code from input to output via complex internals, so I could see where tool calls happened in the flow. There’s a lot of code here, some packages I’ve never worked with before, and concepts I was unfamiliar with, but the nice thing about using the skill was that it reduced the amount of cognitive load by just pointing me to the relevant information.
What it did
You can see the full output file saved from the session in the collapsible block below, but essential the key things it did were:
- create an ASCII diagram of code flow to refer to
- get me to read the relevant bits of code by asking me small scoped questions
- correcting any mistakes I make in my response
- summarising my responses and the connection between what I’d learned and the original goal
I found it really useful - I’m not sure how long it would have taken to understand this bit of the codebase without the extra help, but I suspect it would have been a long week of intense frustration!
(I’d already examined this loop in a previous session, so the agent drew a diagram to help me refresh my understanding and trace through how #858 fits into it.)
The ASCII diagram created by the agent
chat$chat("hello")
|
+-- complete_dangling_tool_requests() [no-op on happy path]
+-- user_turn("hello") [wraps input into Turn with ContentText]
|
+-- chat_impl(turn) [THE LOOP]
|
+-- submit_turns(user_turn)
| +-- chat_perform(provider, ...)
| | +-- chat_request() [GENERIC: provider builds HTTP request]
| | | +-- chat_body() [GENERIC: provider builds JSON body]
| | | +-- as_json() [GENERIC: per provider + content type]
| | +-- req_perform() [httr2 sends HTTP request]
| |
| +-- accumulator$add_turn() [parses response]
| +-- value_turn() [GENERIC: provider parses JSON -> Turn/Content]
|
+-- set user_turn = NULL
+-- assistant has tool requests?
| +-- NO -> loop exits (user_turn is already NULL)
| +-- YES -> invoke_tools() -> tool_results_as_turn() -> reassign user_turn, loop back
|
+-- return assistant turn
What the LLM saved as output from our conversation - including the speech-to-text transcription I used to chat with the model (tidied up slightly for readability) - can be seen below.
Working with the skill
Getting the skill
You can get the raw markdown for the skill at https://github.com/thisisnic/rapid-learning/blob/main/SKILL.md or check out the full repo
Installing via Claude CLI
Alternatively, if you’re using the Claude CLI, you can install it by running:
/plugin marketplace add thisisnic/rapid-learning
/plugin install rapid-learning@rapid-learning
Customizing for your needs
It is pretty tailored to me, and what I’d actually recommend is using the overall framework as a starting point and writing your own.
Caveats and Recommendations
Model performance varies
I’ve had different degrees of success using the skill based on the model I’ve been using. I’ve been working mostly with more capable Claude models like more recent versions of Sonnet, Opus, and Fable, and got pretty good results.
Before I released the skill, I did experiment with DeepSeek V4.1 Flash and Claude Haiku 4.5 to see if it was compatible with cheaper models, but unfortunately I got much worse results. Failure modes varied, but included things like incorrect assumptions made about the coding concepts I was trying to learn, overly complex or verbose explanations, and poor teaching practices like single letter variable names.
Best practices
Regardless of model, I recommend trying this out with a concrete problem to solve or concept to learn about an existing codebase, as that’s where it’s really helped me the most.
Try speech-to-text
Another thing that I found particularly helpful is using some sort of speech-to-text input so I can ask my questions naturally without having to type them. I’ve installed an app on my phone that allows it to function as a Bluetooth keyboard and talk directly to my laptop.