The state’s side of the agreement is to grant you an exclusive right, or monopoly, to the invention for a certain amount of time. Your side of the agreement is to provide enough information to the public so that, once the agreement expires, the public can use that information to put the invention into practice.
The agreement is memorialised in a patent specification that your patent attorney will prepare for you. So, the specification has two functions. It must define the invention so that the reader will understand the scope of your protection. And it must provide a description of one or more examples of your invention so that the reader can practice the invention.
Patents legislation around the world is based on this basic principle. For example, it is self-evident that the state should only contract with you if the invention is not already available to the public. This is covered by the novelty requirement. It also follows that what you are contributing must be of technical value to society. This is covered by the inventive step requirement. Another important issue is ownership. It is also self-evident that the state should only contract with the true inventor. This is covered by the ownership provisions in the patent legislation.
We do see a practical implementation of this principle in the pharmaceutical industry. Once a patent on a certain drug expires, the generic manufacturers often get stuck in and start producing it at a fraction of the price. After all, the testing has been done and there is a full description in the patent.
So, a patent application is a formal request to the state to enter into that agreement. It follows that the patent specification must be filed with the application. It is that document that the state, via an examiner employed by the official patent office, will examine to see if the invention does comply with the novelty and inventive step requirements.
It is possible that you could disqualify yourself from entering into that agreement with the state. For example, a public disclosure, such as a sale, before filing a patent application could destroy the novelty of the invention. In that case, there is no motivation or reason for the state to enter into that agreement with you, because the invention is already available to the public.