As supervisors, many times we are asked to write recommendation letters. In my case, I have been recently asked to write one for a student, who is looking to enroll in a Ph.D. program. Due to the short time working under my supervision and the lack of results, it is not easy to highlight their strong points. In fact, It is also difficult to emit my recommendation. What would you do if you were in my shoes?
If you wrote a lukewarm letter, you probably wouldn't be doing your student any favors! So here's my suggestion:
I'm excited to hear about your interest in pursuing graduate studies. But at this time, I don't have enough information to write a strong letter. If you're still looking for a recommendation next year [next semester], I'd be happy to revisit this decision.
I recommend delivering your decision in person.
Decline on the grounds that, indeed, you've worked too little together.
However (and actually adding to Peter K.'s answer), a discussion in order to understand why they chose you might be useful -- meaning that usually one asks for recommendation from people with whom they've worked longer. If their background and intentions don't seem suitable, maybe also tip them that another career path would be better?
Either decline to write it or get them to write a draft.
The other option would be to engage with the student and have a conversation with them about the "job" and see what their reaction is to what you think the qualities are that would make them successful. Do they have those? Can they convince you that they do?