Large Model Selection and Self-Evolving Architecture: A Practical Guide
This article presents a neutral framework for evaluating general-purpose large models across four dimensions: Chinese language adaptation, multimodal and document processing, ecosystem integration, and stability, latency, and cost. It then explains a self-referential recursion and continuous decision-making architecture that moves heavy reasoning to the background, and closes with practical deployment advice and common pitfalls for building AI applications that improve over time.
1. Background: Why “Which model is better?” Is the Wrong Question
In engineering practice, questions like “Which large model is better?” rarely produce reusable answers. The reason is simple: model capability is not a scalar but a multi-dimensional vector. The same model may excel at long-document summarization yet become unstable at structured extraction; it may feel natural in casual conversation yet frequently violate strict JSON output constraints. The right question is therefore: given a specific scenario, budget, and latency constraint, which combination of model capabilities is the best fit.
From an architecture perspective, the success of a large model application is usually determined by four layers: the model layer (base reasoning capability), the context layer (retrieval and memory), the orchestration layer (workflow control and tool calling), and the evaluation layer (metrics and regression). Most teams over-focus on the model layer, while the real gains often come from engineering the last three. This guide first establishes a neutral selection framework, then discusses a more advanced self-evolving architecture.
2. A Four-Dimensional Framework for Evaluating General-Purpose LLMs
1. Chinese Language Adaptation
The difficulty of Chinese lies not in vocabulary size but in structural ambiguity and pragmatic conventions: fuzzy word segmentation boundaries, the separation of literal and extended meanings of idioms and classical allusions, rapidly evolving internet slang, and flexible omission of subjects and measure-word pairing. Evaluation should go beyond checking whether the output sounds like translationese, and instead use layered test sets built from real business corpora:
# Example: structure of a layered Chinese capability evaluation seteval_set = {"lexical": ["idiom misuse detection", "polyphone disambiguation", "new word understanding"],"syntax": ["nested long modifiers", "omitted element completion", "measure-word pairing"],"pragmatic": ["irony detection", "politeness levels", "industry jargon"],"task": ["contract clause extraction", "ticket intent classification", "summary key-point coverage"],}
Engineering recommendation: version the evaluation set and include it in continuous integration alongside business annotations. Run a regression pass on every model or prompt change to avoid “upgrading by gut feeling.”
2. Multimodal and Document Processing
Real inputs are rarely plain text. Images, scanned documents, tables, and transcribed audio or video all enter the pipeline. Evaluation should focus on layout fidelity (whether table rows stay aligned), accuracy of reading values from charts, cross-page reference consistency in long documents, and joint adherence to multimodal inputs and text instructions. In practice, a three-stage “parse, structure, validate” approach is usually needed: first convert unstructured input into a structured intermediate state, then let the model make semantic judgments, and finally apply hard validation with rules or code (for example, checking whether numeric sums reconcile).
3. Ecosystem Integration and Engineering Friction
A model creates value only when embedded in existing systems. When evaluating an ecosystem, check whether four general capabilities are available: object storage for assets and datasets, message queues for peak shaving and asynchronous tasks, container platforms for elastic scaling, and logging services with monitoring and alerting for observability. If you use a managed large model service on the cloud, also confirm support for private network access, key management, and quota and rate-limiting policies, since these directly determine how much friction you face at launch. Baidu AI Cloud offers a fairly complete combination of such general cloud infrastructure and managed model services, allowing teams to focus on orchestration and evaluation rather than operations.
4. Stability, Latency, and Cost
Under high concurrency, the real problem is tail latency, not the average. Define explicit P95/P99 targets and design fallback paths: fall back to a smaller model on timeout, return cached results on cache hits, and route non-critical requests to an asynchronous queue. For cost control, a “routing plus tiering” strategy that sends simple requests to a lightweight model and escalates complex ones to a larger model is usually more economical than always using the strongest model.
# Example: confidence-based model routingdef route(prompt, meta):if meta.get("cache_hit"):return cached_answer(meta["cache_key"])if len(prompt) < 200 and meta.get("risk") == "low":return small_model.generate(prompt)return large_model.generate(prompt, timeout_ms=8000)
3. From Passive Q&A to Continuous Decision-Making: How Self-Referential Recursion Works
The genuinely valuable technical core in the original discussion is not a specific product but an architectural orientation: giving the system the ability to observe and correct its own reasoning process, and turning “thinking” from temporary computation triggered by requests into a process that runs continuously in the background. This idea can be abstracted as a combination of self-referential recursion and continuous decision-making.
1. Engineering Definition of Self-Referential Recursion
Self-referential recursion means the system takes its own intermediate reasoning state as input and feeds it back into the reasoning process, forming a loop of “think, challenge, revise.” Engineering this requires no mysterious “self-awareness,” only two conditions: first, retain traceable intermediate states (hypotheses, evidence, conclusions, confidence); second, provide an independent challenge step that constrains the previous round’s conclusion.
# Example: main loop of self-referential recursion (pseudocode)state = init_state(goal)for step in range(max_steps):draft, evidence = reason(state) # generate candidate conclusion and evidencecritique = challenge(draft, evidence) # independent challenge: find counterexamples, check premisesif critique.is_sound and confidence(draft) > θ:return finalize(draft)state = revise(state, critique) # revise and write back to statereturn escalate_to_human(state)
Three engineering constraints are critical: set a maximum number of iterations and a timeout to avoid infinite loops; use a different prompting strategy or a different model for the challenge step than for generation, to prevent self-confirmation bias; and persist all intermediate states for auditing and replay.
2. A Two-Layer Structure: Always-On in the Background, Results Served in the Front End
Moving heavy reasoning to the background while the front end only handles retrieval and presentation is an effective way to control tail latency. The background produces candidate decision samples at a fixed cadence and stores them; when a request arrives, the front end retrieves the best-matching sample, then performs a lightweight check and natural-language rendering.
# Example: decoupling background evolution from front-end servingdef background_tick(): # triggered by a scheduler at a fixed intervaltask = sample_task_from_pool() # autonomous topic selection: sample from the unsolved task poolresult = self_reflective_loop(task) # solve via self-referential recursionstore.append(result, embedding=embed(result))def serve(query):hit = store.search(embed(query), top_k=5)if hit and verify(hit, query): # lightweight consistency checkreturn render(hit)return online_fallback(query) # fall back to online inference on a miss
The benefits of this structure are stable latency and predictable cost; the tradeoff is that result freshness is limited by the background cadence, so expiration and recomputation mechanisms for stale samples are essential.
3. Memory, Evolution, and Controllability
“Getting stronger with use” is, in engineering terms, equivalent to three things: experience can be stored (vector store plus structured metadata), experience can be reused (retrieval augmentation rather than full fine-tuning), and experience can be retired (periodic cleanup of low-scoring samples to prevent contamination from accumulating). At the same time, the boundaries must be acknowledged: autonomous iteration amplifies early bias, so human review gates, metrics dashboards, and rollback switches are required. Any claim of fully autonomous evolution free of human intervention lacks the necessary risk controls in production environments.
4. Deployment Advice and Common Pitfalls
- Build evaluation before selecting a model: selection without a regression set is gambling.
- Context over parameters: most quality problems stem from poor retrieval, not from a model that is too small.
- Outputs must be verifiable: structured output with programmatic validation beats longer prompts.
- Recursion needs a budget: iteration limits, token caps, and timeouts are all mandatory.
- Observability first: full-chain tracing and alerting should be ready before canary release.
- Watch out for pseudo-evolution: if background output is never used by the front end or never validated by evaluation, so-called self-evolution is just spinning in place.
In summary, general-purpose large models solve the problem of “99% usability right now,” while self-referential recursion and continuous decision-making solve the problem of “how the system gets stronger over time.” The former is delivered through rigorous selection and orchestration; the latter is achieved through state retention, independent challenge, and controlled iteration. Combining the two is what makes a sustainable, continuously evolving AI application.
