In the former case, you can search and analyze when you have ideas or ideas to see if anyone is ahead. If someone is already ahead, how can you find a suitable route within their protection? If you don't even have an idea and only have one direction, for example, you need such a patent, then you need to search and analyze, find inspiration or creativity from a large number of documents applied by others, improve the technology, and then get your own patent.
The latter is to analyze the obtained patent rights, including technology, market, prospects and other considerations, and get a desired value judgment.