It is a well-known fact that Germany suffered from food shortage during World War I, and that there were several causes of this, including in no particular order:
- The blockade restricting food imports
- The blockade restricting fertilizer imports
- Haber-process nitrate production diverted away from fertilizer to explosives
- Labor shortage because so many men had been sent to the front lines
- Shortage of horses for similar reasons
- Late and poorly designed food rationing measures
What seems to be much more difficult to obtain is any kind of numerical estimate for the relative importance of each of these causes. https://everydaylivesinwar.herts.ac.uk/2015/04/food-and-the-first-world-war-in-germany/ confirms that it wasn't just loss of imports:
As men and horses were called up, farmers' wives took over the running of the farm, but lack of equipment, fertiliser and manpower, even though some 900,000 prisoners of war worked on the land, saw substantial falls in crop yields, which almost halved by the war's end.
Right now I'm trying to get an idea of the importance of labor shortage. The time of year when labor is most needed for food production is harvest. In medieval times, pretty much the entire population, at least everyone able to walk, would help gather the harvest. By 1913, this was no longer necessary. But what happened during World War I? Sure, the men were on the front lines, or buried under them. But there were cities full of women and children who would be perfectly capable of harvesting crops. Were they employed in that capacity? If so, why was there still a labor shortage? If not, why not?
So to ask a specific factual question:
What percentage - or what absolute number - of the German population worked on gathering the harvest in 1917? (I would also be interested in figures for other years. But I pick 1917 in particular because by then, there had surely been enough time to make whatever changes from the peacetime economy, needed to be made.)
I can't find a direct answer to your question, but here are some related data points and references that I hope will be helpful.
First some caveats to how the question is framed here. 1) The raw number for one year wouldn't tell us much, nor the proportion of the total population; we should be much more interested in knowing the proportion by which it fell during the war. 2) The scale of the labor force doesn't tell you much without relation to productivity. As your question alludes to, there are many factors that could impact productivity independent of the number of laborers on the land.
Putting those caveats aside, the most directly relevant detail I've found to the question as you frame it is from Encyclopedia Britannica: "Only 40 percent of Germans lived in rural areas by 1910, a drop from 67 percent at the birth of the empire." (The full data behind this is on Wikipedia.) This is roughly proportional with the fact mentioned in the "Rural Society" article on 1914-1918 Online: about 30 percent of the men in the German army came from the peasantry. On the other hand though, this same article also mentions that in the city of Freiburg, "over a third of the households farmed their own plot or had vegetable gardens." So not all food production was rural.
The book War Experiences in Rural Germany: 1914-1923 by Benjamin Ziemann (2007) doesn't seem to have the kind of figures you are looking for, but it does describe the day-to-day lives of farmers in rich detail. It mentions that, at least in 1915-1916, soldiers were given temporary leave during harvest and planting times (p. 46). Another relevant point is that rural women indeed worked hard to make up for the shortage of male labor, to such an extreme point that "more and more peasant women managing alone suffered from abdominal pains and miscarriages as a result of the constant physical overexertion (p. 158)."
I also checked The Economics of World War One by Broadberry and Harrison (2005) and The First World War: An Agrarian Interpretation by Avner Offer (1991) without much luck. Both discuss the overall question of food shortages in Germany during the war, but none directly give much detail on the scale of the rural labor force per se.