As a Caltech lecturer/instructor, I get a lot of requests for recommendation letters. Here is some information that you should know if you want me to write you a recommendation letter. In what follows, I'll assume that you, the reader, are the one requesting the letter of recommentation.
I'm generally willing to write you a letter of recommendation under the following circumstances:
You're a current Caltech student or recently-graduated former Caltech student.
You took one or more of my courses, and did well, or:
You worked for me as a teaching assistant.
In addition, it would help a lot if the position you're applying for is one in which the material I've taught you (i.e. computer programming) is relevant. So, if you're applying for grad school in a CS program, that's great. If you're applying for grad school in e.g. a theater program, it's not as optimal.
Under some exceptional circumstances, I might be willing to write a letter of recommendation for someone who isn't in the above categories. If you're not sure, email me.
If I am going to write you a recommendation letter, I would appreciate getting some information from you:
All the information about the program you're applying to, including all necessary forms, due dates, web sites, etc. as well as a description of the program itself (or the project, if it's a summer project e.g. a SURF project).
Your full Caltech grades transcript. NOTE: If you send me your transcript, you must also send me written authorization to look at your grades in the transcript (an email from your Caltech email address is sufficient). If you don't, I'm not allowed to look at it even if you send it to me. Rules are rules. Naturally, I will not disclose any of the information on your transcript to anyone, not even to the recipient(s) of the recommendation letter. If you want them to know your grades, you can tell them yourself.
The term/dates of any course you took from me, along with the subject (e.g. CS 11 C track, Fall 2022).
Any relevant work experience e.g. a programming internship. You should describe your job in detail, emphasizing the programming-related aspects of the job.
Any relevant hobby work you've done e.g. any open source project you've participated in, any fun program or programs you've done, etc.
Your programming experience outside of the classes you've taken with me.
Any other information relating to your programming experience.
Any other information you think is relevant.
You are under no obligation to send me any of this information, and I may decide to write you a recommendation letter even without it, but the more information you send me, the better a recommendation letter I can write, and the more likely you are to get accepted into the program you're applying to.
I'm very busy, so it's possible that I'll forget about your request, especially if you ask me far in advance of the due date. Therefore, you should remind me periodically (but no more than once a week). In particular, if the deadline is coming up and you haven't heard from me, send me an email.
If it's at all possible for me to submit the recommendation online (e.g. by typing into a web form) then please let me know. This is a lot easier for me to do, and you'll get your recommendation sent out much earlier.
If you ask me to write you a letter of recommendation a week before a deadline, don't be surprised if I never write it. To get results, ask well in advance.
If the recommendation is successful (e.g. you get into the program you want), I'd appreciate hearing about it! Good luck!