So in the government contracting space there's effectively two kinds of work that are relevant here:
- products, which Palantir claims to be
- services, which Palantir appears to be by offices and head count
You are right that product contracts (and associated services like installation and training, O&M, etc.) can be fairly sticky, but the government has been on a trend towards open-standards, open-source etc. and proprietary software products are under lots of pressure to be incomparably better than anything else out there.
But "cheeks-in-seats" service contracts are not. The government is notorious at tossing out incumbents on service contracts and bringing in new companies, who then simply hire all the people who worked on the previous contract.
Palantir seems to push themselves out there as a two-product company with some sales-staff. It's obviously not going to be turn-key software, there's likely to be some configuration and support stuff up-front. But once you, as a product company, get big enough, even those tasks can be handled competently by other companies. [1] But their product sales don't look to be a huge dollar amount. fbo has a couple awards from 2011 for ~$750k licenses. This is four years ago, but we're not looking at dozens of millions of dollars.
edit here's an award for $20m for Palantir support to the war in Afghanistan. Note that DoD only reports contracts over $6.5m. So the bulk of their DoD awards must be falling under that threshold.
edit here's a 5 year contract from DoJ for ~$10m. http://www.govconwire.com/2014/04/doj-selects-palantir-softw... hardly $20billion dollar valuation contract sizes.
So it's likely most of their growth trajectory has been in specialized consulting services that direct customers to their products, but also use other tools and solutions. But again, once the ecosystem is big enough, the government can just try to compete that work out and hire another company to handle that work...companies that might not direct the solution-space towards Palantir's products.
1 - https://www.palantir.com/partnerships/service-providers/