Say we are given a complex manifold $X$ and an $\mathcal{O}\_X$-module $\mathcal{F}$. Assume that for any point $P\in X$ the stalk $\mathcal{F}\_P$ is a free $(\mathcal{O}\_X)\_P$-module of finite rank. Does it imply that $\mathcal{F}$ is locally free? If not, what do you need to know additionally about $\mathcal{F}$ to make it true?


Note that if we were looking at the case of schemes then it would be wrong in general. Mathoverflow answer to a related question is 
[here](https://mathoverflow.net/questions/44839/wikipedias-definition-of-locally-free-sheaf)


**Remark:** As it was pointed out by Francesco Polizzi, this is true if $\mathcal{F}$ is coherent. What if we do not know it apriori?



Sheaf with free stalks
Just looking at stalks is not enough:


Suppose that $X$ is a nontrivial complex manifold. Let
$i\_x:x\to X$ denote the inclusion, and set
$$\mathcal{F} =\bigoplus\_{x\in X} i\_{x\*}\mathcal{O}\_x$$
Notice that
it is naturally an $\mathcal{O}\_X$-module with $\mathcal{F}\_x\cong \mathcal{O}\_x$,
and yet it is certainly not locally free.




---


**Notes**
Rather than editing, I'll keep the original form of my answer in tact and add a few footnotes.


1. Of course, this $\mathcal{F}$ is not coherent.
2. (Re: UG's first comment.) I probably should have included the proof that $\mathcal{F}\_x\cong \mathcal{O}\_x$. Here it is. The left is the direct limit 
$$\varinjlim\bigoplus\_{y\in U} \mathcal{O}\_y$$ 
as $U$ shrinks to $x$. There is a projection $p$ to $\mathcal{O}\_x$ which is surjective
since it has a section. Suppose that $f=\sum f\_y$ lies in the kernel of $p$. Shrink $U$ to
avoid the support of $f$ (which excludes $x$). Then we see that the class of $f$
in the direct limit must be zero. (There is a reason I took the sum and not the product.)
3. (Re: Laurent's comment.) By $i\_{x\*}\mathcal{O}\_x$, I meant the skyscraper sheaf associated to $\mathcal{O}\_x$.


