doufangzhang4454 2010-01-07 16:51
浏览 49
已采纳

使用PHP获取Noun,Adj,Adv

How to get english other states when I enter 1 state.

I mean

I have a noun and I want to get other adjustment.

$word_list=get_list('play','n');

and then I want to get v , adj, adv, etc.,..

  • 写回答

2条回答 默认 最新

  • drtwqc3744 2010-01-07 19:27
    关注

    You going to need a dictionary and a way to connect related words (Manually?). Well once you have a database of all the words in the dictionary and how they are related then its pretty easy from there.

    For example if you store your dictionary like this:

    id | word      | noun | adverb | adjective | etc.
    1  | play      |  1   |   2    |     3     | ...
    2  | playfully |  1   |   2    |     3     | ...
    3  | playful   |  3   |   2    |     3     | ...
    4  | quick     |      |   5    |     4     | ...
    5  | quickly   |      |   5    |     4     | ...
    

    Then you can make a query like:

    SELECT adverb FROM dictionary WHERE word = 'play'
    

    And you can query the word corresponding to that id.

    In short its gonna be a lot of work...

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥50 本人复制了一个关于股票指标的代码,但是运行失败,有没有人帮我解决一下
  • ¥50 用matlab和numeca做透平机械流体力学和热力学模拟 价格可议
  • ¥15 Unity3D WebView
  • ¥20 论文AlphaTensor复现(有偿)
  • ¥15 (有偿)在ANSYS中 .anf文件
  • ¥45 关于#芯片#的问题:组合逻辑电路设计
  • ¥15 基与机器学习和时间序列分析预测养老服务需求趋势
  • ¥100 求连续两帧图像在水平和垂直上偏移
  • ¥15 Verilog hdl密码锁设计
  • ¥35 基于python的有ssl加密传输的socket聊天室