Beyond Vibe Coding: How to Scale AI-Assisted Development Without Architectural Chaos
Watch on YouTubeVideo summary
Mushek Yorgan introduces SpecMind, an open-source tool designed to scale AI-assisted development while preventing architectural chaos often caused by isolated AI usage across teams. The core problem addressed is that traditional code reviews fail when AI generates massive pull requests containing hundreds of thousands of lines of code, leading to unmaintainable codebases, duplicate data structures, and costly rework. SpecMind solves this through a structured three-step loop: first, the analyze command parses the existing codebase using Tree-sitter to generate descriptive JSON chunks that form a single source of truth file called system.sm, which contains high-level architecture, sequence diagrams, entity relationship diagrams, and external service integrations; second, the design command creates a specific feature.spec file detailing requirements and logic flows for peer review before implementation; and third, the implement command generates code based on the approved spec while automatically updating the system.sm file and creating a change log.
This approach integrates seamlessly as an extension within existing AI coding assistants like Cursor, Codeium, Windsurf, and GitHub Copilot without requiring changes to established workflows, supporting TypeScript, JavaScript, Python, and C# via Tree-sitter for syntax understanding. By committing the system.sm file and feature specs to version control, the tool ensures that documentation stays up-to-date automatically and new developers have immediate context, allowing engineers to focus on design rather than just coding. Additionally, this method enables teams to test multiple AI implementations against a single specification before selecting the best one, ensuring architecture remains consistent even as the codebase grows.
A key challenge identified in maintaining this system is handling direct code changes made by users, which can desynchronize the actual code from the system.sm file. While Amazon's Hero coding agent offers similar spec features, it lacks the comprehensive design-to-task workflow provided here; specifically, simply asking AI to regenerate the system.sm file after manual edits does not work well because it ignores the history of changes. The ideal solution would be a feature allowing the system to iteratively update the system.sm file based only on changes made since the last point of synchronization, rather than starting from scratch or relying solely on a change log that merely references when files were last edited.
Ultimately, SpecMind represents a significant step forward in managing AI-generated code by enforcing architectural consistency and maintaining an accurate, living documentation of the system's evolution. Although the current implementation lacks the ability to resume state regeneration without restarting the analysis process after direct edits, the tool successfully bridges the gap between rapid AI development and the need for robust, maintainable architecture. By automating the creation of specifications and keeping the single source of truth in sync with version control, it empowers teams to scale their use of AI tools without falling into the trap of architectural drift or unmanageable complexity.
Read the full video transcript
Again my name is Mushek Yorgan and um
today we are going to talk hopefully um
very interesting topic which is VIP
coding or
uh I more prefer to say AI coding. Uh so
for me the difference w coding and when
you don't really understand what's what
it really generates and AI coding when
you are an engineer and AI is basically
generating the code for you but you
still understand what it does right and
um
obviously um it's not a secret that
with current tools that are available in
the market like cloud code cursor
windsurf
codex from openai
They make us engineers like 10 times
more productive. You basically ask what
you want. AI creates the code. It works.
It feels like a magic.
But what if it's not only you that are
using the AI to generate the code, but
your whole team is using it.
So this is when a lot of problems are
arising
and basically this is u my speech is
about how to solve this problem but what
let's start from the problem first
what's the problem so imagine there are
like multiple engineers in the team and
everyone is using AI obviously they are
using some kind of inter isolation
uh there's engineer and AI and they're
chatting together and it might be
possible that one engineer might create
a table another one might create another
table which duplicates some data
The third engineer might create some
service while one of the existing
services might work. So basically each
of these chains separately makes sense
but together that actually can create a
mess right
but
engineers
make mistakes developers I mean we can
make mistakes we can write bad code
that's normal and that's why we had code
reviews right so when you write some
code you send it for review and your
peers review your code give your
feedback and this is how we have been
preventing ing let's say bad code or we
we have been preventing messy code when
different engineers creating the same
stuff in a different way but now in this
new world when AI generates in a single
PR sometimes 500,000 or 2,000 lines of
code obviously like the old way of doing
code review doesn't work anymore like as
a human you can't really review the AI
generated code I mean you can but
probably you will miss a lot of things
there you will be you will not you will
not be able to review all the code
and also I think when you review AI
generated code to be honest in my
opinion it's already too late because
based on my experience especially when
I'm reviewing junior or mid developers
AI generated code what usually
my feedback is like hey can you just
rewrite this all please because it
doesn't make sense at all because this
is what AI it's true not the engineer
sometimes
So and also if if you if you catch these
issues, I think it's already too late
because now uh the engineer should go
and start everything from scratch. So
basically the old style of doing code
reviews doesn't work anymore in this new
world. And now let's multiply this this
problems over five engineers across
multiple screens. And let's say you
don't have a proper solution for this
problem.
uh what you'll end up with is uh with
codebase that is not maintainable and I
was in this situation to be honest I was
managing a team five engineers were shi
like it was a startup and obviously
we're shipping very fast like very very
fast but after few weeks we realized
that code is unmaintainable we are
getting bugs and fixing the bugs
becoming like kind of refactoring take
taking sometimes days sometimes weeks of
rework. So we noticed that we are
getting duplicate tables in our database
schema. We
basically were not using any patterns.
So basically code was garbage. Maybe for
startups it's okay in the beginning
because eventually yeah if you gain
customers then you will be able somehow
to um refactor or sometimes even start
from scratch. But in general, I think
it's very dangerous, right? You don't
want to base your business on a codebase
that is messy. It's it's not
maintainable and you don't know what
might happen in the production.
So that's why basically
why I came up with the idea of spec.
It's an open source project. Uh and I
credit it first for us and we have been
using it um so far. Then the idea of
spec is very basic, nothing complicated
to be honest.
So the it's it's a three-step process.
So first is analyze analyze your
codebase,
then design a feature, then implement a
feature. We'll actually review each of
these steps today and I will also try to
do real demo with real AI coding and
hopefully it will go good. Um but yeah,
let's let's review each step
separately. So first step is analyze. So
let's say you want to you want to start
doing AI coding on an existing project
not a new project and this is usually
what happens in big companies or big
teams or not new startups right you
already have some code base that's there
and you have a team and now you want to
accelerate your development with AI so
if you start using specind the first
thing you would need to do is to run the
analyze command and by the way this um
um spec works in all existing uh coding
assistance. So you don't need really to
switch or you know uh you don't need to
change your processes. You can still
keep using cloud code cursor codex
windsurf github copilot whatever. So it
lives inside of this assistance. We'll
review it later in more details. But in
a higher level what you need to do first
you need to run analyze command. So what
analyze command will do it will
basically analyze all your current
existing codebase.
it will parse it with three and whoever
um doesn't know the tree is basically
understand your code structure and not
just text uh and and then spec also
understands your service layers your
patterns your databases your
dependencies frameworks or you use and
eventually based on all of this it
creates a comprehensive documentation
it's called systems which basically
tells what your project is about and how
it's implemented and covering all of
this.
Uh this is the first step and let's try
run analyze command on one of um
projects I actually vcoded by myself.
Uh yeah so first thing you need to do
basically you need to install um specind
into your environment and as you can see
we support
different um coding assistance. I'm
going to use cloud code for this demo
purposes and I'm going to run spec setup
command on my project and hopefully you
can see it.
Uh if not I will try to kind of uh go
through the generated code. So I run
this and what what this uh yeah first I
set up the code. What it does basically
it copies
the commands which are basically the
prompts into your codebase and also it
installs a CLI that can be later be
used. So now if you go to our clut
folder here
we'll notice we got three commands
analyze design and implement review
let's review analyze for now. So what
analyze basically is it's a prompt for
cloud code which says you know what
whenever developer runs this command
first go and run this MP spec mind
analyze C cla which will generate for
you
you know what let's run it and see what
it does so I'm going to run analyze
command
yeah because I just installed
I guess I need to restart my cloud code.
Let's try again.
Yeah, here we go. Now it's available.
So I'm going to run analyze command. And
here hopefully you can see that first
thing it will do, it will run the CLI,
the analyze. So now this CLI will go
over your codebase and will start
generating
JSON files.
What you see it automatically detected
services in my codebase. I didn't tell
anything right but it went to my
codebase and actually yes I have like a
couple of services like I have admin
service agent crawler. By the way this
project is another AI agent uh for car
buyers. Whenever you want to buy or
lease a car, you you chat with this AI
agent and it's connected to different
dealers and it automatically makes
suggestions for you and um schedules
appointments. That's what AI agent does.
But it doesn't matter in this context.
So it automatically detected these
services for example admin agent crawler
DB is like module more not a service and
web and then under each um under each uh
service it also detected the layers. So
it always tries to find any API layer
any data layer external layer and
service layer and under each layer it
will generate chunk files. So this is
basically uh kind of this is the high
level explanation of your service.
What methods does it have? What classes
you know like everything whatever it
could uh uh kind of get from your
codebase
and then the coding assistant which is
in this case cloud code as you see it's
it's running five different
agents in the background. So now they
are reading these chunk files. So
instead of going and reading the all the
uh all your codebase which sometimes
might be so big that it will not fit in
the context of AI right even now we have
like 1 million uh tokens context but
still it will not be able to fit in one
um
in one uh kind of context. So that's why
first what we do we just like because we
don't care about like implementation
details yet we we um now more care about
the architecture. So basically with the
this chunk files we get a high level
architecture of our project and then we
give this to AI and say hey this is our
project please create a comprehensive
documentation. So I think now it's
working on the documentation as uh
itself. Let's go back to presentation
and we'll come here uh again. So again
let's summarize what analyze does right.
So first it analyze your codebase. It
generates descriptive JSON chunks that
will fit in your AI context. By the way,
even if your codebase is very big, this
will still work. Um then it's basically
runs a prompts against your chunk files
and generate the system SM file. And
what you will have in this system SM
file? Basically you will have this high
level system architecture for your
project. Then you will have per service
architecture if you have multiple
services. By the way, now we are talking
about monorreper project, right?
Imagining that you have multiple
services in one repo.
Also, it will automatically generate
sequence diagrams showing the cross
service flow between your services. And
event and last but not least, it will
generate the entity relationship
diagram. Basically, your database schema
or your database schemas if you have
multiple ones. And now this system SM
file will uh kind of play and be a
source of truth for us. Whenever we want
to understand what our project is, we
need to uh check the system SM file and
also the AI by itself can go and read
this SM file when it needs. Yeah, let's
see if if it's done. It's still working.
Sometimes you know like it it takes like
few minutes. Sometimes it uh might take
more but uh you know what let's continue
presentation and we'll be back I guess
in a minute or so. I see like it already
generated 16,000 tokens. So probably
it's almost done. It might take a little
bit more. Let's go back to presentation.
We will come here. So the next command
let's say we have system smile right it
means okay we have the base now we are
ready to start implementing new
features. So if you remember in the
presentation I mentioned like before AI
how we how we were handling the
implementation right we're writing a
code
and then we are sending the code by
itself for review
what I propose I propose that wait
before
starting implementing the code let's
design the feature but and here by
saying design I mean design in terms of
architecture and technical details let's
create a specific ification file for our
feature and only then we'll start
implementing it. So basically to do it
you just run /design command you tell
your um
your feature description feature
description it can be as short as like I
don't know like realtime notifications
or it can be very comprehensive
description about the feature and then
it will start generating the um
specification just for your feature. I
want to show you this. So, okay. Cool. I
think we got the uh systems SM file.
Let's review it.
Cool, cool, cool. Yes. So, now uh so as
you see it generates spec folder in your
project which obviously you need to
commit and push to g. And here you will
have the system folder which is
basically the JSON representation of
your codebase. You basically don't need
to come here. It's it's just like for
first analyze step. And then we got this
system SM file. And by the way uh as
part of spec I also built an u extension
for VS code for vinser for cursor for
every IDE. Uh so you can preview this
file because basically for AI obviously
this is enough it's it's markdown but
for human if you want to read and
understand what it generated you can
basically preview it. And this is what
what AI basically generated. So as you
can see there's a high level overview
what our project is about.
Then there is high level architecture of
our system. Sometimes this is more
complicated. In our case it's pretty
simple. So here what we see we see that
okay here we have um couple of services.
Then we have our data stores which is
posgress and radius. Then it
automatically detected all the external
services we use in our project. For
example we use openai for LLM. We use oz
for authentication. Lagsmith for tracing
our agent to understand what it
generates. Uh this link is basically for
uh iMessage communication. Google maps
API and me zero for agent memory. Yeah.
So it automatically detected what uh
kind of services we use. Then yeah
here's also some um explanation right
what's uh which uh about each service
like admin service, agent service and so
on. the data stores, external
integrations, some communication
patterns and then oh sorry
okay and then uh it generated the
sequence diagrams. So basically by
sequence diagrams it shows each flow in
my application and here we mean like
flow from user
perspective. For example, this one is
crawl job flow. In in my agent, I have a
crawl job when when I click and it
automatically goes and crawls and scraps
the data from dealers, right? And here
you can see that I hope you can see that
it basically with a sequence diagram
describes that. Okay, this is how the
flow works. So, first it insert a job in
posgress, then it cues a job with
radius, and then it it uh triggers the
crawl service. basically just explaining
how our um agent is implemented. So
basically if you onboard a new developer
you know what you can even give them
this system SM file and say hey go read
this system SM file you will learn
everything about our project you don't
need to read even the code so there are
more uh sequence diagrams obviously I
hope it also generated the entity
relationship diagram here we go so it
automatically found our um entities and
it automatically detects multiple uh OMS
so it automatically detected our
entities uh the types the relations and
everything and it it just like wrote
down and then it generated some more
diagrams for each service and some let's
say summary right so we have our system
sn file and now as you remember we uh
wanted to generate a new future now I'm
going to ask AI to generate
uh for example I want to add a new
feature so the the car buyers can add
for example I don't know favorite cars
like and I'm going to call it like buyer
favorite cars. I mean again I can
provide very long description about my
feature. Let's say I can even provide a
PRD or my I can copy from my Jura ticket
or whatever we have our task but for
demo purpose I think this is enough. So
what design uh command will do now? It
will go and read your system SM file
every time to understand okay what
what's our what's our current state
right and then if needed it will also go
and review your codebase this is this is
basically depends on your system SM file
and your uh codebase uh by itself and
then it will take your um description
and it will start generate specification
file just for that feature. Okay. And
basically this specification file is um
this specification file let's go back to
our presentation.
So now like
instead of like sending your um code for
this feature you you will send this
specification file to your peers and now
instead of like reviewing few thousand
code that AI generated they are going to
review just specification file to make
sure that whatever is written there
makes sense right for example yes we
need a new field or yes we might need a
new service for this feature or yes we
might need to add some new relationship
in our database and so on and and now
human uh can read the specification and
review it
and just approve which means like okay
now we are ready to implement this
feature so that's that's the new process
and everything still happens in your
same code review process so you don't
need to like change the code review
process in general if you are using for
example GitHub for your code reviews and
you are using uh PRs pull requests you
can still use them right I can generate
the spec file. I can open a PR. I can
send my to my team to review and then
when when uh I got approval, I can start
implementing it. So let's go back to our
um code and see where we are.
Okay, I see that it's actively now
generating the feature specification.
Okay, now I have everything. I let me
create the feature spec specification.
Okay, uh let's go back to presentation
and we will come back here. So
let's say we send the specification.
Well, which by the way is very similar
to the S system SM. It just um it just u
only about the the feature
specification, not the whole project.
And by the way, I forgot to mention one
thing to be honest. I'm very sorry. U if
you have any questions during the
presentation, I should mention this in
the beginning. You can scan this QR code
uh and submit your questions. We'll re
Oh, sorry. We will review at the end or
if you want to ask at the end. Yeah, you
can do that as well. By the way, I
vcoded my presentation as well.
Yeah, I even I I even vive coded
something more and I forgot to do that.
I vipcoded a speaker notes
and also I someone from my colleagues
asked to record this and I forgot to
start recording but I even implemented
recorder. So, I'm going to turn it on
now. At least we'll have some part of
the presentation.
Cool. And it will record and
automatically put to cloud. Yeah. Uh I
forgot to do that in the beginning, but
that's okay. Okay. Now, let's go back
where we were.
Yeah. Implement. So, um
hopefully our uh feature specification
is ready. Yeah, it is.
It's just writing now to the disk. And
now for each feature you'll have first
you will have this features folder here
and under each you'll have your like
feature slack which automatically
obviously generated by AI and then
you'll have your each feature
specification here in the another SM
file and we can preview it as well. I'm
not going into much details but I what I
want to highlight it's first it
generated requirements right okay so
what are the requirements functional and
technical requirements for my feature so
it just like just thinks in this way
what what I need to do in order to build
this feature and what is very important
it highlights the services it's going to
touch it says you know what I need to
change the agent service and I need to
change the database and that's right
because it doesn't need to change
crawler or the web I didn't ask any UI
change or I didn't ask any admin change.
So that's why it automatically
highlighted that I'm going to change
this service and me as a reviewer I'm
going to review this and say yeah that
makes sense that's cool and if if I want
to get more details okay what are you
going to modify I can read for example
it's saying you know what I'm going to
create a new um inm value and I'm going
to create a new tool which is correct
I'm going to create a new manage
favorites tool for LLM
I'm going to create a new server service
for API endpoint and I'm going oh look
and it says no new source existing buyer
vehicles interest table used with new
source value so it turned out that I
have some table and I think that oh you
know what instead of like creating new
one I can reuse it and probably it's
also highlight in the ER database uh ER
diagram yeah here it's saying you know
what I'm going just to change this table
and I'm going to add this new field and
me as a reviewer I'm looking if if I for
example notice that it's creating a
completely new table I must say hey wait
but why you are doing that right let's
say it's a new engineer join our team
why you are creating a new table
actually we had a we have a table that
you can use so in this way I can review
the specification and just give my kind
of uh approval and then we can say okay
me as engineer who who wanted to
implement this feature I'm ready to
implement it and that's the last step
which is implement now I'm just going
and telling AI hey this feature
specification is okay by the way uh if I
want to change anything here, I can do
it manually. I mean it's not only AI. I
can go and change here or even even I
can chat to AI and say you know what uh
no I want to create
a new table for example let's say for
some reason which is in this context is
not correct but it's not that we are
fully kind of uh automating the process
it's I mean or delegating to AI we still
can inter we can change whatever uh AI
thinks but in general the idea is that
I'm working on my spec file, not code.
I'm talking to AI. I'm changing a lot of
stuff, but I'm not changing the code
yet. I'm changing the feature
specification. That's it. And then when
I'm ready, I'm uh running implement. And
yeah, what implement does basically it
detects your feature specification file.
It just basically starts implementing
based on it, right? Automatic and then
automatically updates the system SM
file. So your architecture is always up
to date which is very important right
because sometimes we create documents
but we as human are lazy or engineers
are late and we never go and uh update
them and and if you're moving like super
fast with AI I mean probably you will
not be able to keep it up to date. So
now Specman will do it for you and also
it creates a change log a separate file
when it just like writes every change
you did. So if you want to understand
how you ended up with this, you can read
the change log. Now what is very
important when you have a feature
specification file and as you know with
AI the cost of implementation now is low
right basically you just ask AI to do it
and they do it that's it now you can
give the your feature specification to
five different AI assistants you can ask
cloud code to implement it then you can
ask codeex to implement it and you can
like look and choose any version that's
the good thing about uh specification
and by the way this specification thing
is not something I came out with it's
called like specdriven development. It's
it's pretty new thing which means like
let's first work on our spec and then
think about specification and even if I
implement it and I don't like my
implementation I can just trash it
because it's AI generated. I didn't spec
spend hours on it, right? I can just
like delete it completely and and start
again because I have all my um
engineering results in my specification
file. And that's why we engineers are
being paid, right? We are not being paid
just for coding. We are being paid for
engineering things, designing things,
thinking and you know like designing a
proper solution that can work. So with
with uh future specification, you can
just like give it to multiple assistants
which sometimes I do. And they take the
version you like most.
Uh and finally let's just
Okay, it's asking to change uh changes
to my specification file. I will say no.
You know what? Because I know that my
request was not a good one. I will just
now ask implement
implement buyer favorite
car. And I mean I can do typos here. it
will it will probably detect uh which
feature I'm referring to and it will
start okay look what it's saying let me
read the feature spec and understand
what needs to be implemented and this
will take more than other steps so let's
go back to our presentation
yeah so uh basically with specime we
create this loop right so first we
analyze which is
one time operation we don't need to
analyze our codebase every time then we
design a feature, we send it to team
team review, we implement it, the
documentation is up to date and then we
go to design, review, implement, update.
That's the loop actually.
Yeah, I mean test is is part of
implementation. Yeah, I I I missed that.
That's a good collab. Probably I need to
add. Yeah, but basically um uh
everything which is related to um
testing, deploying and you know like
running your unit test, running your
integration test uh all of that part in
this context is part of implementation.
Uh
yeah so as I mentioned in the beginning
so spec is in already integrated with
cloud code winds cursor uh I'm working
on codex um soon um because I'm using
three sitter uh basically adding a new
language is not very very
hard thing but it still requires some
time so if you are interested to
collaborate this is a good area you can
collaborate
Uh basically I only have Typescript,
JavaScript, Python and C# um uh
integration. So yeah, let's kind of
understand what we get with Specmind. So
before Specmind, the problem was that
each developer was working isolated with
with with their AI and which basically
creates architecture drifts and usually
you catch problems very late and which
is costly
which I faced. Um but with with spec
mine basically you have this uh the AI
has the full context. Uh you basically
design before coding and uh architecture
stays kind of in sync and consistent and
docs are automatically up to date. So
you kind of keep the speed but you don't
um end up with chaos.
So obviously as I mentioned it's a open
source project. If you are interested um
please scan this QR code. Uh if you like
it please give me a star or fork it or
whatever or you can even if uh you can
try if you see issues you can open
issues or or even open PRs as I said
there are areas for contribution
um
and yeah now let's go to questions but
before that so
let's see what it's doing here. Yeah. So
basically now it's implementing uh the
feature based on our specification.
Let me close this.
Okay. So now AI has a clear picture what
it needs to do. Cool. It started
implementing it. So we can review this
at very very end. Uh but if you don't
mind I would like to do a
selfie with you guys if you don't mind.
Uh I'm so excited that so many people
joined my presentation. So I want to fix
this moment.
Thank you. And now let's go to questions
if you have any. Oh, we have questions
here. Cool.
I was not expecting this. So let's read
them.
Uh how does this compare to openspec?
Um
yeah to be honest uh I think it's one
just um um I think it's just another
implementation of specdriven
development. Uh and there's another cool
project by the way from GitHub. I think
it's called spec kit. So you can check
that as well. I'm thinking to maybe
integrate also to to uh to this um kind
of projects. Uh but uh I probably don't
have deep understanding of the openspec
so maybe I can't give you a good answer.
Um
now
after spec generation does it become
part of the system or does it live
separately? Could you explain the
long-term integration?
after specking the generation sorry does
it become part of the system file
oh okay so yeah basically when you
generate the system SM file it's now in
your codebase so basically you commit as
you do any other file right and you have
also g history on top of it it generates
change log
and I think at the end I will show what
the change log is but also you can
commit it same about the features so
features are in your codebase and they
stay there and you commit them and
obviously uh why you need to do this
because whenever uh new developer joins
or even during the work like when
developers fetch and pull from repo
obviously all of them need to have all
of these feature specification files and
system file right uh and sometimes you
might even get merge conflicts on
systems SM files as as with any other
file obviously um
is this thing on
okay if it's about spec mind yes during
analyze it creates a bunch of chunk
files to form the system SM file I
understand that we need system SM for
any feature development but can we
discard it actually that's a very good
question uh yes now these chunks are
used once so basically you can discard
them I was thinking that maybe I need to
you know like periodically or again
after each implementation update this
chunk file as well because you know what
sometimes happens sometimes AI might
hallucinate and I don't know forget to
update the system SM file it it's
happening very rarely but let's say if
it happens I always want to have the
source of truth which is my chunk file
which is generated deterministically
right which means like it's it's true
there is no hallucination I want still
keep it up to date as well bless you uh
I was thinking about that but for now at
this moment yeah you can basically
discard it because you just used once.
Um,
curious YSM extension over MD. Um, yeah.
So, obviously YSM because it's spec
mine. Why not use MD?
uh because
actually what I did
in my extension as you noticed I'm using
mermaid diagrams and um
I think uh the diagrams were not
automatically being rendered in VS code
but I think they are rendered in GitHub
so I just wanted to render them and I
couldn't with MD file and I didn't want
to change the uh kind of the previewer
for MD file so So I just came up with
new extension which is SM. That's it. I
don't know maybe I overthink uh but uh
that's that's uh why I did SM just to
have this extension so I can have full
control over it to be honest which is
also open source which is also in the
project.
Can the system SM file get so large to
be problematic to break into the context
or is there some logic? Um
yeah I I think I have a issue in my
GitHub project. So it's not happening
but I think in theory it can happen. Uh
it it depends uh on your project size
but because spec now works only for
monorreas. So if you have very very big
projects most probably you are you are
not on monorreo you have multiple repos.
So this is how I control the size of
system smile. But I was thinking that to
have some um chunking logic for system
SM file as well or some you know like u
split into separate uh logical uh parts
you know instead of having just one
file. Will PHP be added to your road map
anytime soon? Um
so yeah again to be honest uh
so far I was doing this totally alone
and I was getting only feedback from
teams I was working on. If I start
getting feedback hey we need PHP yeah
probably I will do it. Um and if you
want you can even try to add that uh by
yourself because you can use AI to add
this integration to be honest right. So
uh but yeah I mean uh if I start getting
some feedback I will start adding more
languages and uh PHP might be one of
them.
What do you think about having the test
creation as part of the plan step rather
than implementation step this will or
against? Yes that's a very good
question. So I have some more ideas. Uh
to be honest I want to now um split
implement step into more steps and one
of them is test. Another one is a plan
you know like I want to take a feature I
then I want to create a test plan. uh
and and then I also want to create a
implementation plan you know like just
get more understanding how AI is going
to do and give less let's say judgment
to AI how this should be implemented you
know like I want to make sure that the
specification file is so well documented
that whatever AI does it just like just
kind of different style of coding but it
will not make bad or wrong decisions so
but I I think creating a test plan
separately is a very good colot and by
the way uh now whenever I'm vibe coding
or AI coding any anything uh I usually
try to start from test so obviously unit
test integration test but what uh I do
more now with AI is simulation test so
whatever AI I'm creating I create
simulation test for them basically
creating scenarios
so I can give to to my agent get the
output and assert on the output to see
like okay how it will behave I don't
know like is this part of integration or
what but usually I do simulation test
and um yeah and and I think probably
this will be good another good step to
add to generate you know this simulation
but simulation tests are only for AI
agents when you are building
nondeterministic system if you are
building deterministic one basically
unit test and integration test will
cover your scope
language agnostic. What amount of token
credit usage was used for your example?
Uh good call out. Let me let me check.
Um yeah, I I think it will be hard to uh
>> sorry.
>> Oh,
right.
But it's still doing that's the problem.
I think it's still implementing. But
let's see what it will give because I
think the most of the tokens will go on
the implementation by itself. Uh
to be honest, I'm now using cloud code
max and
I just stopped thinking about tokens
because uh before that I was using
windsurf um that that was coming from my
team and yes I was always checking my
tokens. I was always buying extra
tokens. Um I'm not promoting any of them
but my personal preference is now cloud
code uh because basically I just don't
care about tokens anymore. There's a
limit which I never reach and I and I AI
code a lot nowadays. So yeah but uh um
so basically if you generate the code
without specind most probably you will
spend the same tokens as it will spend
when implementing. So you are spending
extra tokens on uh specification
generation but in this way you prevent
the future ray implementations. So in a
long term probably you just uh save
tokens. So um but I don't have numbers
to prove this to be honest.
Uh
do we have more questions?
Language agnostic uh with question mark.
I mean it's not language agnostic
actually. uh in terms of that I need to
support each language separately. So I
support
if that's the question to be honest I
support these languages Typescript,
JavaScript, Python and C#. Why? Because
this is the languages I use. Uh but yeah
pro probably like
Go I know is pretty popular. Rust, Java,
I mean C++ I don't know just popular
language I wanted to have on my slides
to be cool.
Um what is the workflow of uh
implementing the new language support?
So basically what I do um so first uh I
just explain what I want to do right
with with u I use spec mine for my
project as well now uh and then what I
do usually I go and vibe got another
project with that language some you know
like mock project for example to do
usually I do like task management system
implemented by Java for example right uh
and then I just run the spec mind on
that project to to do human test and see
what it what it generates. But I don't
have to be honest um
good designed automated testing yet. I
think yeah I I have I have I have unit
tests for of course uh but
during this time I was just asking my
friends to use spec and give me
feedback. That's how to be honest I was
improving it. Yeah, but that that's the
process basically and again I'm using
three-seater. So uh to understanding the
a abstract syntax tree u that's part is
delegated to three-seater. So the only
part specbind um handles is
understanding the patterns the layers
some um let's say dependencies OMS to
because it it's not looking to your
database it's looking to your entities
to build your entity relationship
diagram. So you need to understand the
syntaxes. So are if you're using drizzle
or entity framework or whatever it
automatically understand oh these are
your entities. Oh then these are the
relationship. So it pulls from your uh
entities not the database. Um
>> and we have a couple questions from the
audience.
>> Yes please.
>> So uh notice one back here first.
>> Great presentation. Um, could you just
go over the basics of like uh say you're
a beginner vibe coder, how you work with
git and get github so that you when
you've created something you don't lose
it because sometimes I just go in
circles for half a day and nothing's
accomplished.
Uh,
yeah, let me rephrase your question. I
don't think I understood it like how how
I handled not to lose the context or can
you repeat the question? Sorry. Well,
I'm a beginner vibe coder and I tend to
vibe code, but I don't really have a
good workflow with GitHub yet. So that
when I do work,
>> okay,
>> going back to it, I could spend all day
and then lose what I did.
>> Oh, I see. Okay. Uh, okay. So, yeah, if
you're vibe coding, uh, so are you an
engineer or I guess no, right? Okay.
Yeah. So, if you're vibe coding, um, the
good thing that u you can even ask AI to
do the GitHub stuff for you. That's what
I do nowadays. I I stopped manually
running g or g status or g commit or
whatever. So what you do so first thing
you need to create a project in GitHub
right so that's that's the part that you
need to do it manually I guess and just
copy the URL from the GitHub give it to
AI and say hey this is my g project
please pull it or do whatever so I need
to have my code there and whenever you
are creating a feature any feature and
you see that it works just tell AI that
hey please push this to GitHub that's it
and it will push that chunk of code to
the GitHub automatically what it does
under the hood commits. It creates a
commit and it push to main or you can
say I mean if if if you work in a team
this is not something you need to do you
need to open PRs but if you are alone
and if you're vive coding just say push
to uh GitHub after every meaningful
iteration okay and then you will have
everything in your GitHub. Yeah. Any
more questions?
Yes, please.
>> Hold on. No.
Hey, so um I'm wondering though because
my codebase is split across a an
absolute boatload of services in
completely different repos, but they all
speak the same language and they all of
course depend on uh you know libraries
and similar to talk to each other.
What's the recommended way in spec mine
to handle a lot of repos given you only
talked about the monor repo use case?
Yeah. So I have like just for
information I have that in my uh list to
support uh multiple repos let's say
multi-repo solutions. But for now what
you can do basically you can um open uh
you you can have like per repo kind of
assistant right with it spec setup and
then you can have another agent which
you open in your root folder where all
your repos are and you just ask and you
just dis explain them hey I have this
repos and there are feature
specification files here here there and
then if you want to come up with any
let's say I don't like integration or
whatever you can ask the agent but to be
honest the uh ultimate solution will be
just uh adding that support to spec in
my opinion uh or any specdriven
development uh tool so that's I have in
my list but that's the probably the best
advice I can give you yeah
>> cool uh could we could you talk a little
bit more about the disposable chunk JSON
files right I believe those are created
from trees sitter right um but could you
explain why they're disposable or
one-time use or did I get something
confused there?
>> Yeah, sure. So, um basically why what
are these JSON files and why I need
them? So, what I do so basically to in
order to generate the system SM file the
AI needs to understand your codebase,
right? Basically, so uh the one way of
doing this will be asking AI, hey, go
and check my codebase and generate uh
documentation. I tried that it I tried
that it it it's not always working well
because it's using different search
algorithms and most probably it will
pull some of the files and when it feels
that oh I have high level understanding
it will just start generating
documentation on top of it. what I'm
doing I'm generating JSON files from my
codebase basically uh to
ignore the implementation of my methods
let's say if you go if our unit is one
method right I just ignore the
implementation of the method by itself
but I want to understand all my
relationship between methods classes and
services uh which is less information
which can be included in the context so
that's why I run the CLI to generate
these JSONs which basically are kind of
some kind of a graph on top of my code
and if for example if you look to this
uh API layer I have this JSON files and
I have a summary which um explaining my
chunks and then each each chunk it's
it's kind of it has some representation
in terms of for example uh this one is
because this is a API layer it has all
the APIs for example it says call caller
name post I don't know arguments
location
receiver you know for example if I go to
my data layer I will have another
representation probably about
yeah uh about modules and entities and
everything so then these chunks now are
small enough to just inject into the
context that's the reason only and
because it's used only once for
generating the system SM file because I
hope that uh moving forward You will
always use spec mind to generate these
feature files. So you'll have
commumulative updates in terms of
feature specs. So you don't need this
anymore. So that's why you can basically
delete them.
>> It's just around bootstrapping the
project.
>> Yes. Exactly. Okay.
>> Yeah.
>> Thank you.
>> History
is like set of versions of system
files and and the log files that have
the changes from one version to the
other. That's it.
>> Uh that's a good question. I think
implementation is done. So I can show
you. So
>> the chunks you just throw away. You say
you discard. So they're just like
temporary.
>> Yeah. Yeah. Yeah. So basically you just
>> repeat the question for the uh
>> sorry repeat the question.
>> Yeah. For the audience.
>> Yeah. So the question basically u let's
say you you implemented multiple
features. Uh what's the kind of version
history? What what you have right? So I
have only one system file. I'm not um
it's only one. it just being updated
after each implementation. But I have a
change log and as you can see it
generated one change log right. If I
want to understand how this uh system SM
file uh evaluated I can always come to
this u change log and here it tells what
it did and why it did with notes and
also I get this u feature specification
file. So basically you'll have bunch of
feature specification files here. you
will have just one system file and you
have all your changes in this change
log. That's it.
>> Okay, thank you. Um, yeah, so this is
very interesting. I I actually use a uh
Amazon's hero uh coding agent which has
a similar spec feature but it's not as
comprehensive as this is basically start
with green field create requirements
design and then tasks. Uh so this kind
of ends on top of that by uh examining
existing code bases which is great but
uh uh how do you handle uh having code
get out of sync with the spec right? It
seems like if somebody makes just
changes to the code directly that's
going to pretty much break the whole
thing and then it's going to be hard to
get back.
>> Yes, that's a very good question. So the
question is what if someone just u
change directly in the code? So now the
the system SM and and code are out of
sync. uh that's why I was thinking to uh
implement this feature so I can
regenerate the SM file you know
iteratively and that's why I was
thinking that I still need to keep these
chunk files which I don't do now so the
use case you mentioned yes it's a
problem so if if I start using spec mine
and at one point I just stopped uh so my
system SM file will be kind of uh out of
date but uh let's say if if at one point
I want to um resume. I mean I don't
recommend this but uh let's say if
there's you want to do in some way you
can just ask AI to go and kind of try to
update the system asm file but it will
not work well. So basically that's a
missing feature probably that uh which I
have I think I even have in my GitHub
issues. I I addit issues for myself just
to remember. I think I have one of them
to be able to you know like if you just
temporarily stop using it and you want
to resume be able to regenerate the
system SM file not generate from scratch
but just like you know like add whatever
was added after last point. The good
news that I have a change log so I know
when last time you edited it or even I
can look to the g history but yeah I
think uh I think that's a missing point
in spec now if you if you use it you
need to keep using it uh always let's
say
>> any more question
okay looks like that's it let's give our
speaker some love
>> thank you
>> thank you for coming out
Uh there by the way sorry there was a
question where is the presentation uh
I'm going to submit this to uh scale and
I think there should be way of getting
all the presentations so
>> u uh or what you can do
you can connect me on LinkedIn and I can
uh you can DM me and I can send it to
you as well.
>> So this is my LinkedIn URL and my QR for
my LinkedIn.
There's a live stream right now on
YouTube and the videos should be edited
out uh very very soon. Can't say.
>> Oh, cool.
>> Thank you.
>> Thank you everybody for coming for
coming.
Have a great rest of your day at scale.