Post-Training Optimization or New Foundation Models: How to Choose a Large Model Strategy
This article compares two strategies for improving large language models: intensive post-training on an existing foundation model, and building a larger foundation model from scratch. It explains the technical mechanisms behind each, why coding and agent tasks serve as key tests, and how to design a layered evaluation framework. It also covers engineering practices such as hybrid routing, canary releases, observability, and security, and offers a decision framework for choosing between the two paths.
Large model releases have picked up speed noticeably in recent months. The industry debate has shifted from parameter count alone to a more basic question: where do capabilities actually come from? One strategy is to push the capability ceiling of an existing foundation model as far as possible through post-training, reinforcement learning, learning from tool-use trajectories, and inference-time compute. The other is to rebuild a larger foundation model with a newer architecture, then align and adapt it for applications. The first strategy emphasizes iteration speed and engineering control. The second emphasizes capability ceiling and long-tail potential. The two are not a simple case of old being replaced by new. They correspond to different resource constraints, data assets, and business stages.
This article does not focus on any specific product. It treats the trend as a general technical problem. When a team must choose between extreme optimization of a fixed foundation model through post-training and rebuilding a very large foundation model, how should it understand the technical mechanisms of each? How should it evaluate performance on programming and agent tasks, and how should it design a practical engineering plan?
1. Technical Differences Between the Two Strategies
1. Post-training a fixed foundation model: high-density optimization within existing capability limits
Keeping the foundation model unchanged does not mean only doing simple fine-tuning. A mature post-training system usually has several layers:
- Data mixing and curriculum learning: Build high-quality instruction data, code repository tasks, tool-use trajectories, and multi-turn repair samples for the target tasks. Increase training signal density gradually through a difficulty curriculum.
- Supervised fine-tuning and preference optimization: Teach the model task formats, response style, and decision preferences, which reduces wasted exploration.
- Reinforcement learning with verifiable rewards: In settings that can be verified, such as code execution, unit tests, and structured output, use outcome feedback to drive optimization.
- Rejection sampling and distillation: Select successful samples from high-quality trajectories and feed them back into the training set, forming a data loop.
- Inference-time enhancement: Keep improving performance at inference time through multi-sample generation, self-checking, tool calls, retrieval augmentation, and plan decomposition.
- Learning from tool and agent trajectories: Teach the model to call tools, maintain state, read execution feedback, and recover after failures.
The main advantages of this strategy are fast iteration, relatively controllable cost, and a stable deployment pipeline. The foundation model stays the same, so the inference stack, quantization scheme, caching strategy, and safety policies can all be reused. The team can focus on data quality and the task feedback loop. When the task distribution is well defined and the existing foundation model already comes close to business needs, post-training often produces launch-ready results more quickly.
The risks are also clear: the capability ceiling is bounded by the foundation model. If the bottleneck lies in the foundation model’s knowledge coverage, long-context understanding, complex planning, or long-tail multilingual ability, post-training can only optimize within those bounds and is unlikely to produce a fundamental breakthrough. In addition, over-optimizing against evaluation sets leads to overfitting. Reinforcement learning can also cause catastrophic forgetting, alignment tax, and drift in output style. Teams need to monitor regressions in general capability continuously, rather than looking only at scores on the target task.
2. Rebuilding a very large foundation model: trading a longer cycle for a higher ceiling
The core of the new foundation model strategy is not parameter count itself. It is achieving a higher capability ceiling through larger-scale pretraining, higher-quality data mixing, architectural changes, and training stability improvements. Very large foundation models typically show potential in complex semantic understanding, long-tail knowledge, cross-domain transfer, and complex planning. After post-training, they may generalize more strongly on programming and agent tasks.
The problems with this strategy are a long cycle, high cost, and high engineering complexity. Pretraining requires large-scale data governance, training stability control, distributed parallelism strategies, failure recovery, and an evaluation system. After a new foundation model goes live, the team must also redo alignment, tool-use adaptation, inference optimization, and cost evaluation. More importantly, a gain in foundation model capability does not automatically translate into business value. If the task distribution does not match the model’s strengths, or inference costs are too high, the new model may be more capable but not cost-effective per unit of work.
The essential difference can be summarized this way: the post-training strategy raises task success rates within existing boundaries, while the new foundation model strategy raises the boundary itself. The first is closer to using up existing resources. The second is closer to redefining the resource ceiling.
2. Why Programming and Agent Tasks Are Key Tests
Programming and agent tasks have become the focus of this debate because they test several abilities at once and are closer to real production workflows.
1. Programming is not single-turn completion
Real programming tasks usually include repository understanding, multi-file edits, dependency analysis, test generation, error localization, patch repair, and regression verification. The model must do more than write code. It must understand context, follow constraints, and handle feedback from failures. A high score on a single-turn benchmark does not show that the model can converge reliably across multiple repair rounds.
2. Agent tasks test state management
Agent tasks often require planning, tool calls, observing results, updating state, and recovering from errors. A model may perform well on a single tool call but drift from its goal, repeat calls, lose context, or stop too early in long workflows. Evaluation should focus on trajectory quality, not only the final answer.
3. “Feel” must be broken down into measurable metrics
Developers often describe how a model “feels” for coding. That impression can be broken down into first-pass success rate, number of repair rounds, proportion of invalid edits, tool call success rate, ability to retain long context, explanation readability, and recoverability from failure. Subjective impressions are valuable, but they must be combined with private task sets, online replay, and human review to avoid being misled by public leaderboards or demo cases.
3. Evaluation Framework: Do Not Rely on a Single Total Score
When comparing the two strategies, build a layered evaluation system:
| Dimension | Post-training a fixed foundation model | Rebuilding a very large foundation model | Key focus |
|---|---|---|---|
| Capability ceiling | Constrained by the foundation model | Higher potential | Long-tail tasks, complex planning, cross-domain transfer |
| Iteration speed | Fast | Slow | Time from data loop to launch |
| Training cost | Relatively low | High | Compute, data governance, failure recovery |
| Inference cost | Controllable | May be higher | Latency, throughput, cost per task |
| Deployment stability | High | Requires re-adaptation | Inference stack, quantization, caching, safety policies |
| Data loop | Depends on task data | Depends on large-scale pretraining data | Data quality and contamination control |
| Main risks | Overfitting, capability ceiling | High cost, slow migration, uncertain returns | Canary release and rollback mechanisms |
The evaluation set should have at least three layers:
- Public benchmarks: Use these to get a general view of capability, but do not rely on them as the only basis for decisions.
- Private task sets: Build these from real business distributions, covering high-frequency, low-frequency, and failure cases.
- Online replay sets: Replay historical requests and tool-call trajectories offline to see how the model performs in real contexts.
An illustrative evaluation pipeline can be written as:
def evaluate(model, suites):results = {}for task in suites:traj = run_agent(model=model,task=task,tools=task.allowed_tools,max_steps=task.max_steps)results[task.id] = {"pass_rate": judge_unit_tests(traj),"repair_rounds": count_repair_rounds(traj),"tool_success_rate": count_tool_success(traj),"invalid_edit_ratio": count_invalid_edits(traj),"latency_p95": traj.latency_p95,"token_cost": traj.token_cost}return aggregate_by_task_type(results)
The point of this pseudocode is not the interface. It is the evaluation principle: record effectiveness, trajectories, latency, and cost together, then aggregate by task type. Otherwise, a model may raise its overall score by handling a few simple tasks well, while remaining unusable on complex ones.
4. Engineering Rollout: Hybrid Approaches Are Often More Practical
For most teams, the workable choice is not either/or. It is tiered routing and hybrid deployment.
1. Task tiering
High-frequency, format-stable, latency-sensitive tasks can go to a small model or a fixed foundation model optimized through post-training. Low-frequency, complex, or long-tail tasks can be routed to a more capable new foundation model. A routing policy balances quality, latency, and cost.
2. Canary releases and rollback
A new model should go through shadow traffic, A/B testing, and a small-traffic canary release before full rollout. Monitor first-pass success rate, number of repair rounds, tool call failure rate, timeout rate, cost per task, and human takeover rate. Every capability gain should be backed by a mechanism that allows rollback.
3. Observability
Agent workflows especially need observability. Record each round’s inputs, tool calls, returned results, state changes, and final verdicts. General cloud service categories such as log services, monitoring and alerting, and object storage can help build evaluation and replay pipelines. On Baidu AI Cloud, teams can use general capabilities such as container platforms, object storage, log services, and monitoring and alerting to build an evaluation pipeline. The specific architecture should still be designed around business data and security boundaries.
4. Safety and compliance
Code execution requires sandbox isolation, least-privilege permissions, dependency auditing, and output filtering. Agent tool calls require allowlists, rate limits, and audit logs. Regardless of which strategy a team chooses, security boundaries should not be relaxed because model capability has improved.
5. Selection Guidance: Find the Bottleneck First
The following simplified decision framework can guide the choice:
- If the existing foundation model is already close to requirements on the target task, and the main bottlenecks are format, tool use, and task loop closure, prioritize post-training and inference-time enhancement.
- If failures on long-tail tasks concentrate in knowledge coverage, complex planning, long context, or cross-domain transfer, and post-training gains are diminishing, evaluate a new foundation model.
- If the business is sensitive to latency and cost, prioritize optimizing the fixed foundation model, along with caching, routing, and coordination with smaller models.
- If the business is more sensitive to success on complex tasks and can accept higher cost per unit of work, use a new foundation model for the hard tasks and keep a post-trained model for high-frequency requests.
- Under any strategy, establish a private evaluation set and online replay mechanism first, then discuss which model is stronger.
Conclusion
Extreme post-training optimization of a fixed foundation model and rebuilding a very large foundation model are not simply an old route against a new winner. The first tests data loops, reinforcement learning, and engineering optimization. The second tests pretraining, data governance, and cost control. For developers, what matters is not chasing the buzz around a single release. It is identifying the business bottleneck, building explainable evaluations, designing canary releases and rollback mechanisms, and finding a sustainable balance among quality, latency, and cost. The choice of strategy should serve the task goals, not force the task to fit the strategy.
