生成适合指南的单词(只是为了好玩)

发布于 2024-08-15 04:11:11 字数 471 浏览 6 评论 0原文

我有一些使用指南的测试。使用的指南不需要非常独特,它们只需要是指南即可。随机的指导很无聊 - 所以我试图找到有趣的指导词。现在,我没有比“00000000-feed-dada-iced-c0ffee000000”更好的东西了。理想情况下,我会生成一个动词、名词、介词的列表。

在这个问题上只花了几分钟,这就是我所在的位置:

  1. 我有一个 单词列表< /a> (有点 大)来自 puzzlers.org。
  2. 申请 这个正则表达式来识别单词 可以在 Guid 中使用 (o=0, i=1) ^[ABCDEFOI]{1,8}$
  3. 眯着眼睛。

为什么没有人有一个有趣的指南生成器可以让我立即满意?你会如何处理这个问题?欢迎就如何改进这个特殊指南生成过程提出任何建议。

I have some tests that use guids. The guids used don't need to be enormously unique, they just need to be guids. Random guids are boring - so I'm trying to find fun guid words. Right now, I don't have anything better than "00000000-feed-dada-iced-c0ffee000000". Ideally I'd generate a list of verbs, nouns, prepositions.

Having only spent a few minutes on this problem, here's where I am:

  1. I have a word list (somewhat
    large) from puzzlers.org.
  2. Apply
    this regex to identify words that
    could be used in a Guid (o=0, i=1)
    ^[ABCDEFOI]{1,8}$
  3. Squint.

Why doesn't someone have a funny guid generator available for my immediate gratification? How would you approach this? Any suggestions on how to improve this special guid generation process are welcome.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

望笑 2024-08-22 04:11:11

您开始的解决方案正是我的处理方式。看起来有人已经为您完成了这项工作:

http://nedbatchelder.com/text/hexwords.html

The solution you started is exactly how I would approach it. And it looks like someone already did the work for you:

http://nedbatchelder.com/text/hexwords.html

岁月蹉跎了容颜 2024-08-22 04:11:11

这不是一个技术答案,而是:

《Daily WTF》不久前发表了一篇文章,描述了一个人写了与您想要创建的内容完全相同的类型,这也是《Daily WTF》材料的原因是因为生成器最终吐出了听起来像脏话的东西。

来自The Daily WTF - 自动诅咒生成器

马尔可夫链!”他脱口而出。“我们可以使用统计文本分析来生成由自然音素组合组成的随机单词。它们不会是真正的单词,但它们会符合预期的英语模式,人们将能够完全自然地发音和阅读它们。”

我敢打赌,如果你读了这篇文章,你会得到关于如何改进你已有的东西的想法在职的。

This isn't a technical answer but:

The Daily WTF had a post a while back, describing a guy who wrote the exact type of thing that you are trying to create, the reason it was Daily WTF material is because the generator ended up spitting out things that sounded like curse words.

From The Daily WTF - The Automated Curse Generator

Markov chains!" he blurted. "We can use statistical textual analysis to generate random words built up from natural phonemic combinations. They won't be real words, but they will match expected English patterns, and people will be able to pronounce and read them completely naturally."

I bet if you read that post you will get ideas about how to improve upon what you already have working.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文