Trying to find a left adjoint

Let $\mathsf{Idem}$ be the category of sets that come with an idempotent endomorphism, i.e. the objects are pairs $(A,e)$ where $A$ is a set and $e:A \to A$ is an idempotent. The morphisms $f:(A,e) \to (B,d)$ are morphisms $f: A \to B$ in $\mathsf{Set}$ such that $df = fe$. Let $U\colon \mathsf{Idem} \to \mathsf{Set}$ be the forgetful functor.

I would like to find a left adjoint $F$ for this functor. I tried the functor $F$ where $F (A) = (A , 1_A)$ on objects, and $F( f\colon A \to B ) = f: (A, 1_A) \to (B, 1_B)$, on morphisms, but I can see no isomorphism $$\mathsf{Idem} ((A,1_A), (B,e)) \cong \mathsf{Set}(A,B).$$ I initially thought to send a map $f\colon (A,1_A) \to (B,e)$ to $ef\colon A \to B$, and a map $g\colon A\to B$ to $g\colon (A, 1_A) \to (B, 1_B)$ but this doesn't seem to be right.

Does anyone have any advice about how to find such a left adjoint? I am not sure how to spot one. It seems that the functor has to incorporate some information about all the idempotents because we need $$\mathsf{Idem} \left( FA, (B,e) \right) \cong \mathsf{Idem} \left( FA, (B,e') \right) \cong \mathsf{Set}(A,B),$$ if $e, e'$ are two different idempotents. Any help would be appreciated.

-
Where does this question come from? (book, course...) – magma May 16 '12 at 22:51
It was part of a question on an example sheet for Part III category theory at Cambridge. I'm not sure where it originally comes from. – Paul Slevin May 17 '12 at 2:24

Let $F(A)=A\times\{0,1\}$, with $p:F(A)\to F(A)$ given by $p((x,t))=(x,0)$ (for any $x\in A$, $t\in\{0,1\}$). If $B$ is a set with an idempotent map $e:B\to B$ then any map $g:A\to B$ gives us $g':F(A)\to B$, defined by $g'(x,1)=g(x)$, $g'(x,0)=e(g(x))$, which makes $F$ left adjoint to $U$.
I don't know how user8268 went about it but one way would be to say if $F$ existed it would preserve coproducts and sets are easy, they're all coproducts of $\{\star\}$, so we only need to find $(X,e):=F(\{\star\})$. OK, you want $\mathrm{Idem}((X,e),(B,d)) = B$, so $X$ needs a point $x$ to pick out an element of $B$, and it needs to have $e(x)$ as well. Furthermore $e(x) \neq x$, because that's not "free enough": some points of $B$ might not be in the image of $d$ and if $x=e(x)$ we couldn't map to them. So we need at least $X=\{x,e(x)\}$ and clearly that is already enough. – Omar Antolín-Camarena May 15 '12 at 20:14