Blog
Engineering
AI
4
minutes

GenAI: A New Paradigm for Problem-Solving with Undefined Inputs

Traditional programming is built around well-defined inputs and deterministic logic. Developers write functions that take structured inputs, apply a predefined set of operations, and return a structured output. This model works well when the input space is predictable, but it struggles with problems where inputs are ambiguous, unstructured, or constantly evolving.
Romaric Philogène
CEO & Co-founder
Summary
Twitter icon
linkedin icon

Generative AI introduces a new programming paradigm where the input does not need to be explicitly defined. Instead of crafting rigid logic to process an input, we define the expected output format and use a prompt as a functional description of how to transform the input. The system then dynamically generates the best possible response, validated against the expected structure.

This approach unlocks solutions to problems that were previously difficult to model with traditional programming techniques. Let's explore this concept with examples and discuss its implications for software development.

The Traditional Paradigm: Defined Inputs, Defined Outputs

In classical programming, a function is designed with a strict contract:

def extract_product_price(text: str) -> float:
"""Extracts the price of a product from a structured input string."""
match = re.search(r"\$\d+\.\d{2}", text)
return float(match.group(0)[1:]) if match else 0.0

print(extract_product_price("The price of the item is $12.99")) # Output: 12.99

Here, the function expects a structured input where the price follows a known pattern (e.g., $12.99). If the format changes significantly, this function will fail.

But what if we need to extract prices from unstructured text? Imagine dealing with various formats:

  • "The cost is twelve dollars and ninety-nine cents."
  • "€10,99 in Europe."
  • "Price: 15 bucks."

Writing rules to cover all these variations would be tedious and fragile. This is where GenAI shines.

The GenAI Paradigm: Undefined Inputs, Standardized Outputs

Instead of crafting complex regex rules, we can define the expected output structure and let a large language model (LLM) handle the extraction dynamically.

import openai

def extract_price(text: str) -> float:
"""Uses GenAI to extract a price from any text format."""
prompt = f"""
Extract the price from the following text and return only a JSON object:
{{"price": number}}.

Text: {text}
"""
response = openai.ChatCompletion.create(
model="gpt-4",
messages=[{"role": "user", "content": prompt}],
temperature=0
)
output = json.loads(response["choices"][0]["message"]["content"])
return output["price"]

print(extract_price("The cost is twelve dollars and ninety-nine cents.")) # Output: 12.99

Key Differences:

  1. Unstructured Input Handling: The input can be a sentence, a phrase, or a mix of languages.
  2. Declarative Function Logic: The function doesn’t "parse" the text directly—it describes what it expects.
  3. Format Validation: The AI must return a valid JSON object, ensuring standardization.

Solving Previously Hard Problems

Many real-world problems were difficult to solve with traditional programming because they required extensive rule-based processing. GenAI makes these problems tractable:

1. Extracting Information from Free-Form Text

  • Traditional approach: Regex, NLP pipelines, entity recognition models.
  • GenAI approach: Prompt-based extraction with standardized output validation.

Example: Extracting Job Experience from a Resume

def extract_experience(resume_text: str) -> list:
prompt = f"""
Extract work experience from the given resume and return a JSON list of jobs.
Each job should contain: "company", "position", "years_experience".

Resume: {resume_text}
"""
response = openai.ChatCompletion.create(
model="gpt-4",
messages=[{"role": "user", "content": prompt}],
temperature=0
)
return json.loads(response["choices"][0]["message"]["content"])

This works across various resume formats without predefined parsing logic.

2. Generating SQL Queries from Natural Language

  • Traditional approach: Manual query writing or limited keyword-based generation.
  • GenAI approach: Convert text descriptions into valid SQL queries.
def generate_sql(query: str) -> str:
prompt = f"""
Convert the following request into a SQL query. Assume the database schema
is for an e-commerce platform with tables: users(id, name), orders(id, user_id, total_price),
products(id, name, price).

Request: "{query}"

SQL Query:
"""
response = openai.ChatCompletion.create(
model="gpt-4",
messages=[{"role": "user", "content": prompt}],
temperature=0
)
return response["choices"][0]["message"]["content"]

print(generate_sql("Get the top 5 customers who spent the most."))

Without writing a SQL parser, we can generate structured queries dynamically.

GenAI as a New Tool in the Developer Toolbox

GenAI is not replacing traditional programming, but it adds a new paradigm that complements deterministic logic. Instead of handling every possible input variation manually, developers can define the desired output format and let AI handle input variability.

Where This Paradigm Works Best

  • When inputs are unstructured: Emails, conversations, scanned documents, free-form text.
  • When transformation logic is flexible: Summarization, language translation, query generation.
  • When the output format is well-defined: JSON responses, function calls, structured data extraction.

Where Traditional Programming is Still Better

  • Highly deterministic workflows: Banking transactions, safety-critical systems, low-level computation.
  • Performance-sensitive applications: High-speed processing that requires low latency.
  • Strict business rules: Tax calculations, legal compliance rules that must be explicitly defined.

Conclusion

GenAI shifts how we approach certain classes of problems by allowing unstructured inputs while maintaining structured outputs. It doesn't replace traditional programming but expands what’s possible, making previously hard problems solvable with simple prompts.

For developers, this means embracing a hybrid approach:

  • Use traditional programming for well-defined logic.
  • Use GenAI where inputs are unpredictable, but outputs can be standardized.

This is a powerful addition to the developer’s toolbox - one that should be embraced to build smarter, more adaptive software.

Checkout the articles below to see how we use AI for real-world use cases at Qovery 👇🏼
Share on :
Twitter icon
linkedin icon
Ready to rethink the way you do DevOps?
Qovery is a DevOps automation platform that enables organizations to deliver faster and focus on creating great products.
Book a demo

Suggested articles

SecurityAndCompliance
DevSecOps
 minutes
Qovery Achieves SOC 2 Type II Compliance

Qovery is officially SOC 2 Type II compliant with an Unqualified Opinion. Get the highest assurance of continuously verified security controls for enterprise-grade application deployments and simplify due diligence.

Pierre Mavro
CTO & Co-founder
Product
Observability
 minutes
Troubleshoot Faster with the New Log Search and Filtering in Qovery Observe

Following the launch of Qovery Observe, we’re progressively adding new capabilities to help you better monitor, debug, and understand your applications. Today, we’re excited to announce a major improvement to the Logs experience: you can now search and filter directly within your application logs.

Alessandro Carrano
Lead Product Manager
Platform Engineering
DevOps
Terraform
7
 minutes
Top 5 Crossplane Alternatives & Competitors

Go beyond Crossplane. Discover Qovery, the #1 DevOps automation tool, and 4 other IaC alternatives (Terraform, Pulumi) for simplified multi-cloud infrastructure management and deployment.

Morgan Perry
Co-founder
AWS
Platform Engineering
DevOps
9
 minutes
10 Best AWS ECS (Elastic Container Service) Alternatives

Compare the top 10 AWS ECS alternatives, including Qovery, Docker, EKS, and GKE. Find the best solution to simplify Kubernetes, automate DevOps, and achieve multi-cloud container deployment.

Morgan Perry
Co-founder
Platform Engineering
AWS
Kubernetes
DevOps
9
 minutes
10 Best EKS Alternatives: Simplifying Kubernetes for Modern Development

Compare the 10 best EKS alternatives for Kubernetes, including Qovery (IDP), GKE, DOKS, and OpenShift. Simplify operations, reduce costs, and accelerate deployment.

Morgan Perry
Co-founder
DevOps
Kubernetes
Platform Engineering
15
 minutes
Top 10 Openshift Alternatives & Competitors

Because various organizations need cloud application and service management that offers different levels of simplicity, cost-effectiveness, or feature sets than OpenShift, this article will review its top alternatives to help readers make an informed decision aligned with their specific infrastructure needs.

Morgan Perry
Co-founder
AI
Infrastructure Management
Product
5
 minutes
GPU workloads on EKS just got way simpler with Qovery

Running GPU workloads on EKS has never been easy, until now. With Qovery’s latest update, you can enable GPU nodes, configure GPU access, and optimize costs automatically, all without writing a single line of YAML or touching Helm charts. Qovery now handles everything behind the scenes so you can focus entirely on your applications.

Alessandro Carrano
Lead Product Manager
Kubernetes
 minutes
Kubernetes Deployment Strategies: Pros, Cons & Use Cases

Master Kubernetes deployment strategies: Rolling Update, Recreate, Blue/Green, and Canary. Learn the pros, cons, and use cases to choose the right strategy based on your uptime, risk tolerance, and resources. Simplify complex rollouts with automation.

Mélanie Dallé
Senior Marketing Manager

It’s time to rethink
the way you do DevOps

Say goodbye to DevOps overhead. Qovery makes infrastructure effortless, giving you full control without the trouble.