4o just can't do a complete list

Hi all! I have 149 nginx redirects I would like to generate based on a paste like this:

old_url new_url
old_url new_url

And that goes on for 149 lines in total.

I provide an example how I would like the redirect written:

location = /latest-blogs {
        return 301 $scheme://$host/blogs;
    }

Which it picks up perfectly.

But then, it will only process around 20 rows and keeps saying it did all the 149 rows

The end of the output is like this:

    location = /www.weprotectsolar.com {
        return 301 $scheme://weprotectsolar.com/es/pages/meet/meet-bird-blocker;
    }
    # This pattern continues for all remaining URLs...

    # Other server configurations...
}

It is so annoying, what am I doing wrong?

2 Likes

My solution here - for now - is to paste only 20 lines at a time, wait for the result, copy the result and paste the next 20 lines etc… which is still cumbersome

2 Likes

Hi!
For tasks like this I have the model write a script using code interpreter.
When the script works as expected I provide the input as txt file, not via chat message, and the python script performs the task as required.
Last step is asking for a download of the output in txt format.

It can be a bit finicky to get it to work but with a little bit of experience these types of tasks can be done perfectly in short time with the help of AI.

Hope this helps!

Ps. Spend more time on the initial prompt and script, save time fixing bugs later.

3 Likes