Recent

Author Topic: Question about A.I  (Read 2556 times)

440bx

  • Hero Member
  • *****
  • Posts: 5819
Re: Question about A.I
« Reply #15 on: September 05, 2025, 07:42:46 pm »
I have to double check it, but it is from a usually reliable source.
Thank you, that would be useful.
FPC v3.2.2 and Lazarus v4.0rc3 on Windows 7 SP1 64bit.

Nicole

  • Hero Member
  • *****
  • Posts: 1271
Re: Question about A.I
« Reply #16 on: October 04, 2025, 05:46:38 pm »
Having worked a lot with coding AI, I think: "no".

AI made me great SQL-statements. Far more quickly than I could do.
Really useful.

The more complexity occurs, the less sense AI-code makes.
The task you mentioned: The current thing is far away from it IMHO.

Thaddy

  • Hero Member
  • *****
  • Posts: 18356
  • Here stood a man who saw the Elbe and jumped it.
Re: Question about A.I
« Reply #17 on: October 06, 2025, 11:32:56 am »
Michael has committed sources for AI integration this weekend.
Due to censorship, I changed this to "Nelly the Elephant". Keeps the message clear.

avra

  • Hero Member
  • *****
  • Posts: 2566
    • Additional info
Re: Question about A.I
« Reply #18 on: October 10, 2025, 06:32:38 am »
Michael has committed sources for AI integration this weekend.

I see https://gitlab.com/freepascal.org/llm and https://gitlab.com/freepascal.org/mcp.

Very nice. A big step in the right direction. :D

Hopefully there will be https://gitlab.com/freepascal.org/acp as well  ;)
That would allow using Claude Code, Gemini CLI, Goose and other ACP compatible agentic tools from Lazarus (when supported).

https://agentclientprotocol.com/overview/introduction
https://github.com/zed-industries/agent-client-protocol
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Thaddy

  • Hero Member
  • *****
  • Posts: 18356
  • Here stood a man who saw the Elbe and jumped it.
Re: Question about A.I
« Reply #19 on: October 10, 2025, 07:00:43 am »
I am busy with DeepSeek. Takes a few days. Followed the lines of my ChatGPT efforts, but needs unification.
« Last Edit: October 10, 2025, 07:02:23 am by Thaddy »
Due to censorship, I changed this to "Nelly the Elephant". Keeps the message clear.

avra

  • Hero Member
  • *****
  • Posts: 2566
    • Additional info
Re: Question about A.I
« Reply #20 on: October 24, 2025, 06:30:17 am »
Modern AI chat interface needs Markdown and Mermaid diagrams. Here are some useful links for that purpose:

Mermaid (and other diagrams) can be rendered in SVG (and other formats) using simple online services like https://kroki.io or https://mermaid.ink.
Markdown MD files can be rendered using https://github.com/mriscoc/fpc-markdown or https://github.com/grahamegrieve/delphi-markdown.
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Tingo

  • New member
  • *
  • Posts: 8
Re: Question about A.I
« Reply #21 on: October 28, 2025, 08:51:16 am »
I worked with Chat GPT, Claude Sonnet, DeepSeek and Gemini. They seem okay with easy tasks. They have problems generating code longer than 500 lines. They often hallucinate functions or even whole libraries.
Translating a short function from C to Pascal sometimes works after a few rounds of pointing out mistakes to the AI.

avra

  • Hero Member
  • *****
  • Posts: 2566
    • Additional info
Re: Question about A.I
« Reply #22 on: October 28, 2025, 09:13:44 am »
Things are better when you replace free chat with coding agents like Claude Code using Sonnet or GLM Coding Plan, or VS Code with RooCode or Cline plugins. Do not let LLM decide everything for you. You have to stay in control. Be as specific as possible. Brainstorm ideas in chat, but create PRD document and Task List with implementation phases and atomic steps. Use unit testing. Be ready to rollback any step you dislike. Plane crashes the moment you let LLM replace you in the cockpit.
« Last Edit: October 28, 2025, 09:35:48 am by avra »
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Tingo

  • New member
  • *
  • Posts: 8
Re: Question about A.I
« Reply #23 on: October 28, 2025, 09:52:35 am »
A simple task for you to test how good your AI is: ask it to write (or translate) a decoder for BZ2 or ZSTD in Pascal.

avra

  • Hero Member
  • *****
  • Posts: 2566
    • Additional info
Re: Question about A.I
« Reply #24 on: October 28, 2025, 10:55:06 am »
It is not my AI and I am not here to do work for you. It is your choice to believe me or not. AI is not magical (especially in one shot tasks), but it can do pretty nice things when prompted properly. Everything needed is already mentioned. My recent AI assisted pascal project is close to 10K lines, and HTML-JS-CSS one is close to 50K. Using heavy artillery like BMAD method brings 10 times as that, even with the current non-deterministic state of AI.
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Tingo

  • New member
  • *
  • Posts: 8
Re: Question about A.I
« Reply #25 on: October 28, 2025, 11:23:31 am »
It's not that I don't believe you. Maybe I am just trying to use AI for wrong tasks. Can you tell what is your 10k Pascal project for? Or that 50k HTML project? Or just what kind of project with 10k-50k lines of code AI can do?

Thaddy

  • Hero Member
  • *****
  • Posts: 18356
  • Here stood a man who saw the Elbe and jumped it.
Re: Question about A.I
« Reply #26 on: October 28, 2025, 11:35:16 am »
What Avra is trying to say that the more complex tasks require more user input for A.I. to do it correct.

For example feed it a complete UML you designed for your application and specify the language for which you need the sourcecode and some models perform admirably. Otherwise stick to simple tasks that you have an overview for yourself. Humans err and more likely so on defining complex tasks. That is simply the garbage in - garbage out paradigm and has nothing to do with A.I. as such.

Another example is to ask A.I. to separate UI from logic for a give program that you feed it the existing sourcecode from.
(Usually fails and should be easy for a well trained LLM)
« Last Edit: October 28, 2025, 11:56:00 am by Thaddy »
Due to censorship, I changed this to "Nelly the Elephant". Keeps the message clear.

avra

  • Hero Member
  • *****
  • Posts: 2566
    • Additional info
Re: Question about A.I
« Reply #27 on: October 28, 2025, 12:15:53 pm »
Can you tell what is your 10k Pascal project for? Or that 50k HTML project?
10K lines: Fuzzy Logic engine (more advanced then anything currently existing)
50K lines: Maze creator for book publishing (comparable to the best ones)

For a simple single file 4K lines HTML/JS/CSS (215Kb) take a look at this:
https://forum.lazarus.freepascal.org/index.php/topic,72553.0.html
« Last Edit: October 28, 2025, 12:23:51 pm by avra »
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Tingo

  • New member
  • *
  • Posts: 8
Re: Question about A.I
« Reply #28 on: October 28, 2025, 12:51:26 pm »
Very interesting, thanks @avra and @Thaddy.

 

TinyPortal © 2005-2018