Categories
Artificial Intelligence Information Technology IT Engineering Methodology Project Delivery Requirements Engineering Requirements Management Technology UX

Mastering Requirement Engineering: How to Steer Any Project Toward Predictable Outcomes – Part 1

Project success boils down to one critical element: expressing requirements as the essential ‘foundational brick’ of every digital initiative—a lesson my experience leading as CTO, Chief Architect and IT Chapter Lead has taught me time and again.

Therefore, I will walk you through practical “ins” and “outs” of requirement engineering (all based from lessons learned during my career); by showing concrete and actionable solutions that will work directly when using proper process. And you’ll find that it’s far more dynamic and engaging than you might have been led to imagine.

The Starting Point of Clarity: Shifting Perspectives

The very first stage of any project aimed at establishing or changing a system inevitably involves stakeholders that bring varied perspectives. These stakeholders might arrive equipped with well-defined lists of requirements, or they may simply have a broad notion of what they need.

As seasoned business analyst, enterprise architect, or engineer in requirement engineering, it’s our charge to transform these somewhat misty ideas into concrete operational expectations.

A successful project rests on laying clear, solid building blocks from the start – but what happens when those very building blocks change mid-construction?

Deconstructing the Requirement

A requirement is nothing less than a unit describing the behavior of the system we’re about the construct, or upgrade. And by system, I’m obviously referring to every moving part of the machine here. I mean that is a blend of human input, machine outputs via technology, like the hardware itself, software systems, and sometimes specialized machinery. These factors all will work together to ultimately deliver goods or services to the end user, or consumer.

To describe requirement engineering as a step-by-step activity first we start at an “intake workshop” or initial “intake discussion” which we conduct. I always see that as an interactive interview that requires that stakeholders need be ready. They should be ready in bringing elements on the products or services to be offered. It as all interactions the diverse group who will consume the interaction . In addition to how different process are offered and interface used.

Having stakeholders ready at the door is not by chance; clear expectations early define strong and lasting project success further on.

Two Pillars of Success: Aligning Vision and Action

Business Objectives

From these interactive and in-depth interviews, we usually collect an initial set of business requirements. These encompass high-level organizational objectives — the global perspective from corporate leaders, what that single entity, at a macro level, expects to achieve.

As a concrete example that can also guide your thinking process. A business objective could be in reducing a specific pain by aiming that customer inquiries drop sharply YoY or perhaps aim. It could be also focused at improving service levels by making more efficient exchanges between front line agent and positive 4-star average ratings during 3 consecutive business months.

I am trying to tell you here what the entire business objectives expressed at the corporate level intend to accomplish when significant system refactors go live and are fully online. Remember that very often these type of grand and bold expressions does not precisely detail how results will emerge, I mean, these statements define “the what”— not exactly “the how.”

Individual Stakeholder Needs

Naturally as part of our overall journey we also investigate other pillars. We also cover in deep dives, all needs from all of our direct individual stakeholders. Those, when using this framework, will vary as they reflect individual viewpoints of different stakeholders within that entire new process. These are obviously the real system’s daily participants, and they start directly with the very consumer but also encompass a diverse group of customer representatives. To list even further members, those usually also include product managers, product owners, compliance officials at back- office positions, salespeople, system’s experts and also administrators of key areas.

So in synthesis, this captures requirements at hand when seen from an enterprise, internal, system users. This gives much clarity as how the system will need to behave from any angle possible to move further efficiently. Those stakeholders, these key needs or statements must absolutely initiate with a dedicated role’s identifier. And always, this unique role should clearly specify who performs which objective. Although a specific name, which does not change, could also fulfil the same need, it is recommend practice when using roles: the user might change over specific time and it also provides the benefit of being universal and interchangeable. We typically associate roles to a purpose describing specific mission with the very scope over our proposed enterprise solution.

For example, it reflects how an consumer should really be welcomed, or given needed support. Or exactly how the user receive help to fulfil exactly their goals and this translates practically in action. To describe it, or express in real business use case – or user stories -, we should use keywords of the quality or standard of mustshould, or could; or in an easier more customer oriented or “human readable” tone, the typical statements of want or could according to established principles of practice like the MoSCoW method; with an object that need specific measurable levels of activity, and these could refer typically as timed elements, or even similar dimensions.

These business requirements and user needs represent the yin and yang needed for a robust requirement engineering exercise… that said, how can a single vision encompass different realities without generating chaos?

Going Deeper

Lets get into more details on requirements. You absolutely should be taking specific points, that must always come to your considerations

Requirements fall into multiple forms and shapes with their nuances. There always will be a business requirements. By that I mean statements encompassing the entire purpose and outcome that must result when viewing it at the top- level. Think big picture; This can refer simply to revenue objectives, but also the general and overall improvement measures from new standards of service or level quality. Maybe even, why would need to change your very organization itself in by adding or reducing key employee functions. In short there should aim any time that new risks diminish across the processes with an even greater growth on specific business categories or customer bases.

Then, always, the stakeholder or even more simply stated user needs should always be on the list and it is just stating things from a concrete daily actions and tasks being required from a normal system’s everyday use and daily journey perspective. That means we include the very customer, any internal team like engineers working in service desk, an administrative expert plus relationship executives, a product lead and their team the real IT team covering areas such an compliance or network infrastructure departments. These all have diverse usage patterns with sometimes vastly diverse daily requirements. Now is that time to take advantage from these unique opportunities being offered in a timely process improvement initiative?

Then come the more refined aspects: all the expressions to define in concrete terms how “the system must work”, taking into consideration every angle. Functional statements, as requirement, does not only cover the idealistic perfect “happy situation but it must consider less likely scenarios and “exceptions cases”. All of this done in order of improving the very solution.

Every statement when dealing with functional requirement must systematically bring other additional questions too: functional, but mainly based on current user’s activities. A proper inquiry must target on how needs achieving business results, when looked through different perspectives that translates into real day-to-day steps to complete a goal being stated as core objectives. For instance. If part of a overall user journey, you must translate even complex workflows with concrete statement which translate as practical system behaviors along various user operations.

We need also to dig into another very specific requirement’s families: the less visible aspect, typically associated a system’s framework such compliance standards for performance that express real world hard, strict constraints. Or what we often coin as simply rules defining parameters, including regulatory statements, corporate norms, industry compliance benchmarks, or specific or established operating frameworks.

For example, if specific or even highly strict certification is paramount, for instance ISO norm 2022 or PCI-DSS norm of the international card processing businesses. As one example among many. Those frameworks brings their mandatory strict operating guide. And these will form that bedrock for all further development at all levels— whether a new or evolving application , an improvement to existing processes or system or even novel products, and new ventures, ensuring there exists no discrepancy when considering what must be done. And more, many businesses already have an internal guiding principles whether or not these are formally integrated for instance in a internal enterprise architecture manual. It means we must always check that aspect first. This can impact by default and most usually is defined from the outset but in rare events it also will emerge at a late, more mature phase, during one that intake deep dive, during session of brainstorming when the proper inquiry has commenced.

A business or process specialist and also an Architect usually must collect initial set of systemic assumptions and the single best and efficient practical means of doing that properly, starts asking good and pointed specific pertinent questions.

This layered approach to discovering and mapping the technical requirements ensures no stone will be left unturned. Do you wonder how you can reconcile these vastly different perspectives in practical project execution terms?

Let’s address this important question in next episode.

Categories
Technology Artificial Intelligence Automation Autonomous Agents ChatGPT GPT4 Information Technology IT Architecture IT Engineering Robots Testing

Navigating the Future with Generative AI: Part 2, Prompt Over Code – The New Face of Coding

In this installment of the Generative AI series, we delve into the concept of “Prompt as new Source Code”. The ongoing revolution of generative AI allows one to amplify one’s task productivity by up to 30 times, depending on the nature of the tasks at hand. This transformation allows me to turn my design into code, eliminating almost the need for manual coding. The time spent typing, correcting typos, optimizing algorithms, and searching Stack Overflow to decipher perplexing errors, structuring the code hierarchy, and bypassing class deprecation among other tasks, are now compressed into one. This minimization of effort provides me with recurrent morale boosts, as I achieve significantly more in less time and more frequently; these instances are micro-productivity periods. To put it in perspective, I can simply think about it during the day, and have a series of conversations with my assistant while I commute. My assistant is always available. In addition, I gain focus time.

I don’t need to wait for a team to prove my concept. Furthermore, in my founder role, I have fewer occasions to write extensive requirement documents than I would when outsourcing developments during periods of parallelization. I just need to specify the guidelines once, and the AI works out the rest for me. Leveraging the  AMASE methodology to fine-tune my AI assistant epitomizes the return on investment of my expertise. Similarly, your expertise, paired with AI, becomes a powerful asset, exponentially amplifying the return on your efforts.

Today, information technology engineering is going through a quantum leap. We will explore how structured coding is being replaced by natural language. We refer to this as prompting, which essentially denotes “well-architected and elaborated thoughts”. Prompting, so to speak, is the crystallization of something that aims to minimize the loss of information and cast-out interpretation. In this vein, “What You Read is What You Thought” becomes a tangible reality.

The Unconventional Coding Experience with AI

Although the development cycle typically commences with the design phase, this aspect will not be discussed in this article. Our focus will be directed towards the coding phase instead.

The development cycle with AI is slightly different; it resembles pair programming. Programming typically involves cycles of coding and reviews, where the code is gradually improved with each iteration. An artificial intelligence model becomes your coding partner, able to code 95% of your ideas.

In essence, AI acts as a coach and a typewriter, an expert programmer with production-level knowledge of engineering. The question may arise: “Could the AI replace me completely? What is my added value as a human?”

Forming NanoTeams: Your AI Squad Awaits

My experience leads me to conclude that working with AI is akin to integrating a new teammate. This teammate will follow your instructions exactly, so clarity is essential. If you want feedback or improvements in areas like internal security or design patterns, you must communicate these desires and potentially teach the AI how to execute them.

You will need to learn to command your digital teammate.

Each AI model operates in a distinct yet somewhat similar fashion when it comes to command execution. For instance, leveraging ChatGPT to its fullest potential can be achieved through impersonations, custom instructions, and plugins. On the other hand, Midjourney excels when engaged with a moderate level of descriptiveness and a good understanding of parameter tweaking.

A New Abstraction Layer Above Coding

What exactly is coding? In essence, coding is the act of instructing a machine to perform tasks exactly as directed. The way we’ve built programming languages is to ensure they are idempotent, repeatable, reliable, and predictable. Ultimately, coding is translated into machine language, creating a version that closely resembles human language. This is evident in modern languages like TypeScript, C#, Python, and Kotlin, where instructions or controlling statements are written in plain English, such as “for each”, “while”, “switch”, etc.

With the advent of AI, we can now streamline the stage of translating our requirements into an algorithm, and then into programming code, including structuring what will ultimately be compiled to run the program. Traditionally, we organize files to ensure the code is maintainable by a human. But what if humans no longer needed to interact with the code? What if, with each iteration, AI is the one updating the code? Do we still need to organize the code in an opinionated manner, akin to a book’s table of contents, for maintainability? Or do we merely need the code to be correctly documented for human understanding, enabling engineers to update it without causing any disruptions? Indeed, AI can also fortify the code and certify it using test cases automatically, ensuring the code does not contain regressions and complies with the requirements and expected outcomes.

To expand on this, AI can generate tests, whether they be unit tests, functional tests, or performance tests. It can also create documentation, system design assets, and infrastructure design. Given that it’s all driven by a large language model, we can code the infrastructure and generate code for “Infrastructure as Code“, extending to automated deployment in CI/CD pipelines.

To conclude this paragraph, referring to my first article in the “Generative AI series”, it is apparent that Natural Language Processing is now the new programming language expressed as prompts. The Large Language Model-based generative AI model is the essential piece of software for elaborating, structuring, and completing the input text into code that can be understood both by human engineers and digital engineers.

The New Coding Paradigm

This fresh paradigm shift heralds the advent of a new form of coding—augmented coding. Augmented coding diminishes the necessity of writing code using third and fourth-generation languages, effectively condensing two activities into one.

In this scenario, the engineer seldom intervenes in the code. There may be instances where the AI generates obsolete or buggy code, but these can often be rectified promptly in the subsequent iteration.

We currently operate in an explicit coding environment, where the input code yields the visible result on the output—this is known as Input/Output coding.

The profound shift in mindset now is that the output defines the input code. To elucidate, we first articulate how the system should behave, its structure, and the rules it must adhere to. Essentially, AI has catapulted engineers across an innovation chasm, ushering in the era of Output/Input coding.

Embracing Augmented Coding: A Shift in Engineering Dynamics

The advent of augmented coding ushers in a new workflow, enhancing the synergy between engineers and AI. Below are the core aspects of this transformation:

  1. Idea Expression: The augmented engineer is impelled to express ideas and goals to achieve.
  2. Requirement Listing: The engineer lists the requirements.
  3. Requirement Clarification: Clarify the requirements with AI.
  4. Architecture Decisions: Express the architecture decisions (including technology to use, security compliance, information risk compliance, regulatory technical standards compliance, etc.) independently, and utilize AI to select new ones.
  5. Coding Guidelines: Declare the coding guidelines independently and sometimes consult the AI.
  6. Business Logic: Define the business logic in the form of algorithms to code.
  7. Code Validation: Run the code to validate it works as intended. This becomes the first order of acceptance tests.
  8. Code Review: assess the code to ensure it complies with the engineering guidelines adopted by the company.
  9. Synthetic Data Generation: Use AI to generate data sets that are functionally relevant for a given scenario and a persona.
  10. Mockup-API Generation: Employ AI to generate API stubs that are nearly functionally complete before their full implementation.
  11. Test Scenario Listing: Design the different test scenarios, then consult stakeholders to gather feedback and review their completeness.
  12. Test Case Generation: Make AI to generate the code of test cases. The same technique applies to security tests and performance tests.

AI can even operate in an autonomous mode to perform a part of the acceptance tests, but human intervention is mandatory at certain junctures. It’s crucial to bridge results with expectations.

Hence, when uncertainties arise, increasing the level of testing is prudent, akin to taking accountability upon acceptance tests to ensure the delivered work aligns with the expected level of compliance regarding the requirements.

Non-Negotiable Expectations

In the realm of critical business rules and non-functional requirements such as security, availability, accessibility, and compliance by design, these aspects are often considered second-class citizen features. Now that AI in coding facilitates the choice, these features can simply be activated by including them in your prompts to free you up more time to rigorously test their efficiency.

Certain requirements are tethered to industry rules and standards, indispensable for ensuring individual or collective safety in sectors like healthcare, aviation, automotive, or banking. The aim is not merely to test but to substantiate consistent performance. This underscores the need for a new breed of capabilities: Explainable AI and Verifiable AI. Reproducibility and consistency are imperative. However, in a system that evolves, attaining these might be challenging. Hence, in both traditional coding and a-coding, establishing a compliance control framework is essential to validate the system’s functionality against expected benchmarks.

To ease the process for you and your teams, consider breaking down the work into smaller, manageable chunks to expedite delivery—a practice akin to slicing a cake into easily consumable pieces to avoid indigestion. Herein, the role of an Architect remains crucial.

Yet, I ponder how long it will be before AI starts shouldering a significant portion of the tasks typically handled by an Architect.

Ultimately, the onus is on you to ensure everything is in order. At the end of the day, AI serves as a collaborative teammate, not a replacement.

Is AI Coding the Future of Coding?

The maxim “And is greater than or” resonates well when reflecting on the exponential growth of generative AI models, the burgeoning number of published research papers, and the observed productivity advantages over traditional coding. I discern that augmented coding is destined to be a predominant facet in the future landscape of information technology engineering.

Large Language Models, also known as LLMs, are already heralding a modern rendition of coding. The integration of AI in platforms like Android Studio or GitHub Copilot exemplifies this shift. Coding is now turbocharged, akin to transitioning from a conventional bicycle to an electric-powered one.

However, the realm of generative AI exhibits a limitation when it comes to pure invention. The term ‘invention’ here excludes ideas birthed from novel combinations of existing concepts. I am alluding to the genesis of truly nonexistent notions. It’s in this space that engineers are anticipated to contribute new code, for instance, in crafting new drivers for emerging hardware or devising new programming languages (likely domain-specific languages).

Furthermore, the quality of the generated code is often tethered to the richness of the training dataset. For instance, SwiftUI or Rust coding may encounter challenges owing to the scarcity of material on StackOverflow and the nascent stage of these languages. LLMs could be stymied by the evolution of code, like the introduction of new keywords in a programming language.

Nonetheless, if it can be written, it can be taught, and hence, it can be generated. A remedy to this quandary is to upload the latest changes in a prompt or a file, as exemplified by platforms like claude.ai and GPT Code Interpreter. Voilà, you’ve just upgraded your AI code assistant.

Lastly, the joy of coding—its essence as a form of creative expression—is something that resonates with many. The allure of competitive coding also hints at an exciting facet of the future.

Short-Term Transition: Embracing the Balance of Hybrid A-Coding

The initial step involves exploring and then embracing Generative AI embedded within your Integrated Development Environment (IDE). These tools serve as immediate and obvious accelerators, surpassing the capabilities of features like Intellisense. However, adapting to the proactive code generation while you type, whether it’s function implementation, loops, or SQL code, can hasten both typing and logic formulation.

Before the advent of ChatGPT or GPT-4, I used Tabnine, whose free version was astonishingly effective, adding value to daily coding routines. Now, we have options like GitHub Copilot or StableCode. Google took a clever step by directly embedding the AI model into the Android Studio Editor for Android app development. I invite you to delve into Studio Bot for more details on this integration.

Beware of Caveats During Your Short-Term Transition to Generative AI

Token Limits

Presently, coding with AI comes with limitations due to the number of input/output token generation. A token is essentially a chunk of text—either a whole word or a fragment—that the AI model can understand and analyze. This process, known as tokenization, varies between different AI models.

I view this limitation as temporary. Papers are emerging that push the token count to 1M tokens (see Scaling Transformer to 1M tokens and beyond with RMT). For instance, Claude.ai, by Anthropic, can handle 100k tokens. Fancy generating a full application documentation in one go?

Model Obsolescence

Another concern is the inherent obsolescence of the older data on which these models are trained. For example, OpenAI’s models use data up to 2022, rendering any development post that date unknown to the AI. You can mitigate this limitation by providing recent context or extending the AI model through fine-tuning.

Source Code Structure

Furthermore, Generative AI models do not directly consider folder structures, which are foundational to any coding project.

Imagine, as an engineer, interacting with a chatbot crafted for coding, where natural language could reference any file in your project. You code from a high-level perspective, while the AI handles your GIT commands, manages your gitignore file, and more.

Aider exemplifies this type of Gen AI application, serving as an ergonomic overlay in your development environment. Instead of coding in JavaScript, HTML, and CSS with React components served by a Python API using WebSocket, you simply instruct Aider to create or edit the source code with functional instructions in natural language. It takes care of the rest, considering the multiple structures and the GIT environment. This developer experience is profoundly familiar to engineers. The leverage of a Command Line Interface – or CLI, amplifies your capabilities tenfold.

Intellectual Property Concerns

Lastly, the risk of intellectual property loss and code leakage looms, especially when your code is shared with an “AI Model as a Service”, particularly if the system employs Reinforcement Learning with Human Feedback (RLHF). Companies like OpenAI are transparent about usage and how it serves in enhancing models or crafting custom models (e.g. InstructGPT). Therefore, AI Coding Models should also undergo risk assessments.

The Next Frontier: Codeless AI and the Emergence of Autonomous Agents

Names like GPT Engineer, AutoGPT, BabyAGI, and MetaGPT herald a new branch in augmented coding: the era of auto-coding.

These agents require only a minimal set of requirements and autonomously devise a plan along with a coding strategy to achieve your goal. They emulate human intelligence, either possessing the know-how or seeking necessary information online from official data sources, libraries to import, methods, and so on.

However, unless the task is relatively simple, these agents often falter on complex projects. Despite this, they already show significant promise.

They paint a picture of a future where, for a large part of our existing activities, coding may no longer be a necessity.

Hence, the prompt is the new code

If the code can be generated based on highly specific and clear specifications, then the next logical step is to consider your prompt as your new source code.

It means you can start storing your specifications instructions, expressed as prompt, then store the prompt in GIT.

CD/CC with Adversarial AI Agent
Continuous Development/Continuous Certification (CD/CC) with Adversarial AI Agent

Suddenly, Continuous Integration/Continuous Delivery (CI/CD) becomes Continuous Development/Continuous Certification (CD/CC), where the prompt enables the development of working pieces of software, which will be continuously certified by a testing agent working in adversarial mode: you continuously prove that it works as intended.

The good thing is that benefits stack up: the human specify, the AI code/deploy and the AI certify, to finish with the human using the results of the materialization of its thoughts. Finally, the AI learns along with human usage. We close the loop.

Integrating New Technology into Traditional Operating Models

AI introduces a seamless augmentation, employing the most natural form of communication—natural language, encompassing the most popular languages on Earth. It stands as the first-of-its-kind metamorphic software building block.

However, the operating model with AI isn’t novel. A generative AI model acts as an assistant, akin to a new hire, fitting seamlessly into an existing team. The workflow initiates with a stakeholder providing business requirements, while you, the lead engineer, guide the assistant engineer (i.e. your AI model) to execute the development at a rapid pace.

Alternatively, a suite of AI interactions, with the AI assuming various roles, like dev engineer, ops engineer, functional analyst, etc. can form your team. This interaction model entails externalizing the development service from the IT organization. Here, stakeholders still liaise through you, as lead engineer or architect, but you refine the specifications to the level of a fixed-price project. Once finalized, the development is entirely handed over to an autonomous agent. This scenario aligns with insourcing when the AI model is in-house, or outsourcing if the AI model is sourced as a Service, with the GPT-4 API evolving into a development service from a Third-Party Provider like OpenAI.

AI infuses innovation into a traditional model, offering stellar cost efficiency. Currently, OpenAI’s pricing for GPT-4 stands at $0.06 per 1000 input tokens and $0.12 per 1000 output tokens. Just considering code generation (excluding shifting deadlines, staffing activities, team communication, writing tasks, etc.), for 100,000 lines of code with an average of 100 tokens per line (which is extensive for standard leet code), the cost calculation is straightforward:

100,000 × 100 = 10,000,000 tokens; (10,000,000 tokens × $0.12) ÷ 1000 = $1,200. This cost equates to a mere two days of development at standard rates.

For perspective, Minecraft comprises approximately 600,000 lines of Java code. Theoretically, you could generate a Minecraft-like project for less than $10,000, including the costs of input tokens.

However, this logic is simplistic. In reality, autonomous agents undergo several iterations and corrections before devising a plan and rectifying numerous errors. The quality of your requirements directly impacts the accuracy of the generated code. Hence, mastering the art of precise and unambiguous descriptive writing becomes an indispensable skill in this new realm.

Wrap up

Now, you stand on the precipice of a new coding paradigm where design, algorithms, and prompting become your tools of creation, shaping a future yet to be fully understood…

This transformation sparks profound questions: How will generative AI and autonomous agents reshape the job market? Will educational institutions adapt to this augmented coding era? Is there a risk of losing the depth of engineering expertise we once relied upon?

And as we move forward, we can only wonder when quantum computing will introduce an era of instantaneous production, where words will have the power to change the world in real time.

🖖